Formal:
* Devoir: This is the most common and versatile translation. It translates literally to "have to" or "must".
* Example: *J'ai dû travailler tard hier.* (I had to work late yesterday.)
Informal:
* Falloir: This is more commonly used in the third person singular, "il faut", meaning "it is necessary".
* Example: *Il a fallu que je travaille tard hier.* (It was necessary for me to work late yesterday.)
* Avoir besoin de: This translates to "to need".
* Example: *J'ai eu besoin de travailler tard hier.* (I needed to work late yesterday.)
Other options:
* Être obligé de: This means "to be obligated to".
* Example: *J'ai été obligé de travailler tard hier.* (I was obligated to work late yesterday.)
* Être forcé de: This means "to be forced to".
* Example: *J'ai été forcé de travailler tard hier.* (I was forced to work late yesterday.)
The best translation will depend on the specific context and the nuance you want to convey.