The past perfect tense is used to talk about actions that were completed before some point in the past. The past perfect tense is used for talking about something that happened before something else.
John had already eaten when Sarah arrived at his house.
When he arrived to the train station, the train had left.
There are two actions in this sentence: eating and arriving. Eating is in the past perfect and arriving is in the past simple, so we know that eating was completed first. When there are two verbs in a sentence, one in the past simple and the other in the past perfect, then the past perfect action finished before the past simple action.
Forming the Past Perfect tense
The past perfect tense is formed by using had + past participle
Forming negative sentences in the past perfect
The helping verb in the past perfect is always had. To make a negative, put not after the helping verb had.
Petra hadn’t eaten all night so she was starving.
Paul had not studied French before he went to Paris.
They had not seen each other for many years.
Forming questions in the past perfect
To make a question in the past perfect, put had before the subject.
Had they dated long before they got married?
How long had Robert lived in San Francisco by then?
Passive in the past perfect
To make a passive sentence in the past perfect, use be in past perfect (had been) and then the perfect form of the main verb.
The city had been defended by the brave men.
The window had been broken by a little boy.
Three banks had been robbed by those prisoners.
Contraction with Past Perfect
When we use the Past Perfect in speaking, we often contract the subject and the auxiliary verb. We also sometimes do this in informal writing:
I’d eaten already.
They’d gone to the shop.
In negative sentences, we may contract the auxiliary verb and “not”:
I hadn’t finished my meal.
Peter hadn’t had a day off for a long time.
The past perfect is often used with words such as before, until, previously, etc. One word that is very common with the past perfect is by.
By the evening, the rain had stopped.
By the end of the semester, Ryan had completed all his prerequisites.
When to Use the Past Perfect
When you are talking about some point in the past and want to reference an event that happened even earlier, using the past perfect is used to convey the sequence of the events. Writing an entire paragraph with every verb in the past perfect tense is very unusual.
When Not to Use the Past Perfect
Do not use the past perfect when you are not trying to convey some sequence of events. If there is no context, so the past perfect does not make sense.