Onlyis an adjective or adverb.
Onlyas an adjective
We useonlyasan adjective to mean that there is just one or very few of something, or that there are no others:
He was theonlyperson in the room.
Being healthy is theonlything that is important to me.
Onlyas an adverb
We useonlyas an adverb to mean that something is limited to some people, things, an amount or an activity:
This phone isonlyavailable in Japan.
Onlya few hundred houses survived the hurricane without any damage.
Onlycan mean ‘simply’:
He’sonlyjoking.
In speaking,onlycan be used withjustfor emphasis. It can mean ‘very recently’ or ‘almost not’:
She’donly justmoved into her new house last July.(very recently)
The building had survived the earthquake of two years before, butonlyjust.(It almost didn’t survive the earthquake.)
Only: position
As an adjective, we useonlyin front of a noun orone, or before another adjective or a number:
Is that youronlycopy of the book?
He was theonlyone who could read in the village.
Not:He was the only who could read…
That was theonlylarge t-shirt left in that colour.
There wereonlyfour United fans in the room.
We can useonlyas an adverb in different positions, depending on its focus. If the subject is the focus, we putonlyin front position:
OnlyJason knows where the key is kept.
Onlya very small bed will fit in this room.
If the focus is on another part of the sentence, we usually putonlyin the normal mid position for adverbs (between the subject and the main verb, or after the modal verb or first auxiliary verb, or afterbeas a main verb):
Ionlygo home once a month.(between subject and main verb)
She hadonlyarrived at midnight the night before.(after the first auxiliary verb)
She’sonlysixteen.(afterbeas a main verb)
If the focus is a whole clause, we can putonlyin front position:
My arm hurts butonlywhen I try to raise it.
See also:
Not only … but also
If only