Most of the country was expected to experience high temperatures, with the Met Office warning in place for the south and large parts of eastern Scotland.
The amber heat warning will last until midnight on Tuesday.
Meteorologists have warned that Scotland's highest recorded temperature of 32.9C (91.2F) could be topped this week.
By late afternoon, the Met Office confirmed Aboyne in Aberdeenshire had hit 31.3C, beating its previous high of 30.1C in June 2018.
At Edinburgh's Royal Botanic Gardens, the temperature peaked at 30.8C, while it reached 29.9C in Aviemore.
It made Monday the warmest day of the year so far.
The Met Office said there was "a good chance" the Scottish record, set at Greycrook in the Scottish Borders on 9 August 2003, could be broken on Tuesday - with up to 35C possible across south east Scotland.
Extreme heat caused the overhead lines between Glasgow Queen Street low level and Hyndland to "sag". The line was blocked to allow engineers to investigate and lines will have to be repaired, causing disruption to services.
A national emergency has been declared in the UK, with an unprecedented red extreme heat warning issued in England.
A high of 38.1C was recorded in Santon Downham, Suffolk, while 37C was exceeded in several places.
While Scotland will be cooler, special precautions and warnings have been put in place to counteract the heat.
* Speed restrictions on ScotRail trains between 13:00 until 20:00 to help reduce any potential damage to railway line and overhead wires
* Painting railway tracks white to reduce heat and prevent metal from expanding
* LNER has cancelled all trains south of York on Tuesday and Avanti West Coast will run a much reduced service on Monday and Tuesday
* Loch Lomond and The Trossachs National Park has urged care around water, emphasising the risk of cold water shock.
* Scottish Water has asked the public to be as efficient as possible with water use, including using watering cans rather than hoses in gardens, not to fill up paddling pools and to take shorter showers
* The Scottish Environment Protection Agency (Sepa) has advised businesses to reduced their water usage to help current water scarcity issues
* Scottish Borders Council said it was trialling an earlier waste collection service in Hawick to make conditions more bearable for staff.
However, some parts of Scotland did not experience the very high temperatures. Residents and holidaymakers in Lerwick, Shetland, donned rain hats and jackets as the top temperature in the port town was a cool 14C.
The risk to health of high temperatures has also prompted the release of public health advice including drinking plenty of fluids, keeping out of the sun and avoiding exercise in the hottest part of the day.
Concern is highest for the very young, those with underlying health conditions, and for the elderly.
Adam Stachura, head of policy for Age Scotland, told BBC Scotland: "The concern we have for older people is they might find themselves overheating or getting sun stroke.
"The really helpful thing to do is to check in on your older friends and relatives, when it is stifling heat like this then they might not be coping so it is important to check on them."
Keith Brown, Scottish government's resilience minister, urged people to "monitor forecasts and follow public health advice".
He added: "Our resilience arrangements have been activated and stand ready at all times to coordinate a response to severe weather issues where required.
"When temperatures increase, it's important to monitor forecasts and follow public health advice, including staying hydrated and drinking plenty of fluids and avoiding excess alcohol.
"Water safety incidents and drownings increase in hot weather and people should be aware of the dangers and use supervised beaches and pools when possible."
Jim Dale, founder of British Weather Services, told BBC Radio's Good Morning Scotland programme the extreme weather was "straight out of the Sahara desert" and evidence of climate change in action.
Mr Dale said: "There's enough records that have been broken in this year alone, in places like Japan, and then come back to Europe - Portugal, Spain, France, Italy - to know that this is the narrative going forward."
During a previous spell of record-breaking weather, Glasgow's Science Centre experienced its roof "melting".
In June 2018, the mercury hit 31.9C and saw the building's weatherproof membrane melt and drip black "goo" down the walls.
In recent weeks, the venue has been undergoing work to rectify this issue.
A spokesman said: "The replacement of our roof is almost complete and there will be a more heat resistant waterproof membrane installed."
The weather alert north of the border affects:
* Scottish Borders
* Dumfries and Galloway
* East Lothian
* West Lothian
* And parts of Perthshire, Falkirk, Ayrshire, Stirling, Clackmannanshire and Lanarkshire.