A heat wave that kicked in late Monday morning for the Bay Area will linger through Thursday night, with record-setting temperatures possible, forecasters said.

The heat is expected to peak on Tuesday and Wednesday throughout the region and areas of the Central Coast, according to the National Weather Service.

A heat advisory has been issued for interior areas, which will see temperatures ranging from the 90s to 104 on the hottest days. Shoreline areas and the Santa Cruz County coast could warm to the upper 80s and lower 90s, forecasters said.

Downtown San Francisco can expect temperatures in the lower 80s while oceanfront areas will peak in the mid 70s. Other coastal areas should remain relatively mild, in the 70s to about 80 degrees, compared to inland areas.

Overnight lows will range from the upper 50s to mid 60s, which may limit the amount of typical overnight relief from the heat, the weather service said.

The heat wave prompted the Bay Area Air Quality Management District to issue its second Spare the Air alert of the season for Tuesday, following a similar alert that was issued for Monday.

“As temperatures and traffic increase in the Bay Area, unfortunately, so does unhealthy air quality,” said Jack Broadbent, the air district’s executive officer. “When it matters most, we can protect our respiratory health and reduce our exposure to smog by avoiding outdoor activities during the hottest part of the day.”