This is something quite common;
When staring at a computer screen, people tend not to blink, therefore your eyes become quite dry.
FFXIV has A LOT of flashing bright lights, this strain on your eyes also causes irritating and eventually headaches on top of the dry irritated eyes also contributing to the headache.
On top of this FFXIV is an MMO with A LOT of information passing on the screen at one time. Consider the eye movements, focus and detail constantly flashing past you every second, this causes quite a lot of strain on your eyes which also contributes towards headaches an then the feeling of nausea.
Lights aren't the only issue, excessive audio and light can trigger migranes, which start slowly in your vision along with a feeling of pain in your head which will slowly start to spread, if you get ANY symtoms of this STOP PLAYING ASAP find a dim/dark and noise free room to relax in. Lay down and do NOTHING (no phones/books/toys) for 15-30 minutes, PAIN MEDICATION WILL NOT FIX THIS.
What can I do to fix/prevent this?
Please bear in mind, sometimes this isn't easily fixed there are A LOT of potential factors, not all of the factors below may affect you.
Faster paced games can cause these issues more-so than slower paced calmer games.
•DO NOT PLAY IN A DARK ROOM. I cannot stress this enough, the flashing light and constant change in colour/tone detail changing will strain your eyes even more in a darker room that a comfortably lit one.
•Oddly enough a wide-screen can also cause this issue, some players report playing games on a 4:3 monitor as opposed to a 16:9 monitor reduces eye-strain and headaches.
•Sit face on with your screen, don't look at it from an angle or from above/below.
•FREQUENT short breaks. Set a time/timer until it becomes like second nature to you. Every 15-30 minutes take a 5-10 minute break.
•Every 10-15 minutes look away from your monitor, find a static object nearby and simply stare at it for a minute or so, your eyes will blink naturally, the static imagry also helps apease the constant visual strain from all the detail and flashing lights FFXIV fetures.
•Players also have a tendency to slouch, most of the time to the point where the player simply doesn't notice, this also puts a strain on the body over time causing joint pains.
Monitor Brightness
•Computer Monitors are designed to emite a bright blue glow to emulate the suns light and provide a crisp clear image.
During the night this isn't nessecary, the monitor DOES NOT need this glow and having this constant strain on your eyes through the entire day will likely cause this issue.
Please consider download this programme;
https://justgetflux.com/
Set your location and the transition to [Slow]
This will dim your monitor in the evening to a halogen glow, reducing your eye strain.
Other possibilities
Diet
A bad diet, malnutrition, dehydration will trigger migraines, eye strain and join pain even faster.
Consider your personal diet and whether it includes what you really need, as malnutrition from certain nutrients may lead to more easily irritated eyes and or headaches/migraines.
Basic Exercise
Simply getting a breath of fresh-air every now and again along with 15-30 minutes of normal casual exercise a day will also help deter some health issues mentioned above.
We're not talking a marathon, just a walk to clear your head or some chores.
Editing the rest as I go.
If your television or monitor is rather bright try adjusting the settings to tone down the brightness (or use FFXIV's gamma correction options).
As someone else mentioned reduce the battle effects;
[Start] > System > Character Configuration > Character > Battle Effects > [Limited/None]
See if this reduction in bright flashing lights helps.
Consider what I mentioned about audio, the sheer amount of auditory diversity may be an issue too, lower your sound-effects volume and increase the music, or decrease both as this may also be contributing to the strain.
Also to re-iterate, make sure you're facing head-on with your screen and not an side, top or low angle.
Edit:
Extra addition:
A low frame-rate can cause issues too, having a lower frame-rate forces your eyes and overall your mind to compensate more for the jar in detail.
30-60fps is ideal, anything lower can sometimes trigger the side affects mentioned above.
///// LAST BUT NOT LEAST //////
If it's really really really bad and frequent, GO AND SEE YOUR DOCTOR.
This is your best source of advice.