Previous experience with 〜た+ことがある
Grammar: Experience » 〜た+ことがある
Past experience is conveyed by appending ことがある to the past-tense form of a verb. こと turns the phrase before it into a noun.
Alternate Explanations
Someone has done something. Someone has had an experience doing something. There was a time when ~.
In general, Sinf-past ことがある expresses the idea that there was a time when someone or something was in a state or did something.
More specifically, Sinf-past ことがある expresses one’s experience. In this case, Sinf-past ことがある is an extended use of the possession expression “A は B が ある”, where B is a past action rather than a possessed thing. This extended use of the possession expression of experience in Japanese is parallel to that in English. Possession: “I have a car.” Experience: “I have [studied Russian.] (past action)”
Makino, Seiichi and Michio Tsutsui. “Main Entries.” A Dictionary of Basic Japanese Grammar, The Japan Times Ltd., 1989, pp. 196–197
The た form of a verb, followed by ことがある, expresses experience: someone has had the experience of doing something or being somewhere.
To express a lack of experience doing something or being somewhere, こと が/は ない is used in place of こと が ある.
Kamiya, Taeko. “Expressing Ability, Preference, Desire, Intention, Resolution, and Experience.” Japanese Sentence Patterns for Effective Communication, Kodansha, 2005, p. 204
Stating Previous Experience (V た ことがあります)
N は V た ことがあります
N has had the experience of doing V.
This pattern is used to indicate that one has had the experience of doing something, and that something is expressed by a verb in the plain-form past tense before ことがあります (“to have the experience”).
Chino, Naoko. “Basic Pattern 38.” A Dictionary of Basic Japanese Sentence Patterns, Kodansha, 2000, p. 228
Examples
Experience returning home for a backpack with 〜た+ことがある

Chiya recalls the time when Syaro had returned home having forgotten her backpack at school.
- 千夜:
- 「シャロちゃんは学校にランドセルを忘れたまま帰ってきた事があったわ」
Experience with sleepovers with 〜た+ことがある

Cocoa thinks Rize is nervous about staying overnight, but Rize explains she’s hasn't had experience with a sleepover except for camping out in the wild with her father’s group, so this is her first time sleeping over with friends.
- リゼ:
- 「いや… 親父の部下に誘われたワイルドなキャンプしか経験した事ないから…」
Experienced a situation in a comic with 〜た+ことがある

Seeing Cocoa’s interaction meeting another girl at the teacup shop, Chino recalls having seen a similar situation in a comic.
- チノ:
- 「こんなシチュエーション漫画でみたことあります」