I have chronic migraines. I have a mental checklist I go through first: did I sleep enough? Did I drink enough? Did I eat enough? Often it's just due to lack of food/water, or poor sleep, and eating/drinking or taking a nap will often help.
Once I've gone through that checklist, I resort to medication. Extra strength advil is usually enough for me unless it's particularly bad. There are triptans you can take (prescription) if your migraines are recurring and particularly bad, but you would have to go to a doctor for them. I have a neurologist I see regularly because of mine.
While you're waiting for medication to kick in, try to avoid bright lights or any other potential sensory triggers. I would usually go lay down with a wet towel on my forehead or something cool for my head and turn all the lights off.