No, it does not. Your ESTA authorisation needs to be valid for when you enter the U.S.
and will allow you to stay within U.S. territory for up to 90 days from when you land.
So, it’s fine if your ESTA does not remain not valid throughout your stay in the United
States. It is important to bear in mind that while your ESTA authorisation does remain
valid for 2 years or until your passport expires, this never means that you can stay
for longer than a period of 90 days. In order to stay in the U.S. for any further
length of time, you will need to obtain a visa. In fact, the official website
of the U.S. Customs and Border Protection agency says the following:
“If the ESTA expires while you are in the U.S., it will not affect your admissibility
or the amount of time you are permitted to remain in the U.S.”
In addition, if your ESTA does expire during your trip, this will not negatively affect your
future travels to the U.S., so long as you do not overstay the 90 days that the Visa Waiver
Program grants you. Of course, while your ESTA does not need to be valid for the entirety
of the duration of your stay, your passport must remain valid up until your departure
and for six months after your arrival.
You will not need to apply for ESTA again before you leave, though you will need a
new one if you would like to visit the U.S. again after your departure. This can be
done at any point before, during, or after your stay, and you do not need to wait until
your current ESTA authorisation period of 2 years (or less, depending on your passport
expiry date) runs out. If you have more than 30 days remaining, you will receive a
warning that you still have remaining time, but you can still renew your ESTA anyway if you so choose.