The cities were selected when the International Olympic Committee met at its headquarters in Switzerland.
The event attracted 3500 athletes from 205 countries when it made its debut on the international calendar in Singapore in 2010.
The Singapore Games were broadcast to 160 countries and watched by 247million television viewers.
The announcement that Glasgow has made it through to the final three was greeted with delight across the UK.
To celebrate, a dance flashmob of more than 100 young people gathered in Glasgow's Central Station calling on the public to support bringing the bid to the city.
Olympic athletes and politicians also welcomed the announcement and pledged to work to win the final vote in July.
The bid team for the Youth Olympics is made up of the Scottish Government, the city council and was supported by the British Olympic Association.
Glasgow, which is gearing up to host the Commonwealth Games next year, received a glowing technical report from the IOC.
Sebastian Coe, chairman of the BOA, said: "It is an honour to have Glasgow shortlisted to host the Youth Olympic Games in 2018.
"London 2012 inspired young people like never before and there is now a once-in-a-lifetime opportunity for the UK to take the next step on the Olympic journey to empower young people globally.
"Glasgow cannot only stage a compact, sustainable and financially sound Youth Olympic Games but take a unique journey in history hand in hand with the Olympic Movement fuelled by the passion and warmth of Scotland.
"A Youth Olympic Games in Glasgow would empower young people worldwide to believe they can be champions in their lives and at the same time, inspire the world to support them."
Young Olympians aged between 15 and 18 will compete in 28 different sports over 12 days of competition.
Glaswegian Katherine Grainger, Britain's most successful female rower and London 2012 gold medallist, said: "For many young athletes, the Youth Olympic Games will be the first step towards competing at the very highest level and it is fantastic to think they may be taking those steps in Glasgow.
"The city has a proven track record of delivering major international sporting events in world-class facilities in front of passionate crowds - something to which any young athlete would respond.
"At the same time, Glasgow has shown a very real commitment to developing sport at all levels, particularly for young people, making the city the perfect host for the 2018 Youth Olympic Games."
Shona Robison, Scotland's Minister for Commonwealth Games and Sport, said: "Having the opportunity to host the Youth Olympic Games is hugely exciting for Scotland.
"My congratulations go to the young people at the heart of the bid.
"Being shortlisted by the IOC is a great honour that cements Scotland's reputation as the perfect stage for world-class sporting events."
Glasgow City Council leader Gordon Matheson said: "We will continue to work hard to show how this city can be a valuable partner of the Olympic Movement to better the lives of young people both here and across the globe."
UK Minister for Sport, Hugh Robertson said: "Our commitment from host- ing London 2012 was to inspire a generation and that is exactly what the Youth Olympic Games is about.
"The people of Scotland would give a warm welcome to the youth of the world and I wish the bid team the very best of luck."
Bid team director Paul Bush said: "The hard work continues to show the Olympic Movement that we have a visionary bid which can seize a unique opportunity to secure guaranteed legacy from last summer's Games and the 2014 Commonwealth Games here in Glasgow."
Glasgow 2014 chairman Lord Smith said: "Hosting another global sporting event in the city will continue to develop real legacy and impact from Glasgow 2014 as well as demonstrating the warmth and enthusiasm the city and Scotland holds for athletes and spectators."