MSPs voted 69 to 59 to mandate the First Minister to seek permission from the UK Government for a ballot to be held between autumn 2018 and spring 2019.
Ms Sturgeon's minority Scottish Government won the vote following an extended debate thanks to support from the Scottish Greens.
Loading article content
Photo credit: PA
The two-day debate started last week but was suspended on Wednesday as news of the terror attack at Westminster emerged.
The vote comes the day after Ms Sturgeon met with Theresa May in Glasgow, and the day before the process for leaving the European Union will be formally triggered by the PM.
The First Minister has insisted her referendum timetable would allow Scottish voters to make a choice when the terms of the UK's exit deal become clear and before it is "too late to choose our own course".
Speaking before the leaders' meeting on Monday, Mrs May said her position will not change, arguing that a vote within Ms Sturgeon's proposed time frame would be unfair to voters and come at a time when the focus should be on securing the best Brexit deal for the whole of the UK.
Ms Sturgeon said she would delay making the section 30 request - the mechanism for the transfer of powers to hold the referendum - until ''later this week''.
She said she ''hoped the UK Government would respect the will of the Scottish Parliament'', but if it does not she will set out her next steps after the Easter recess.
Ms Sturgeon said: "It is now the will of Scotland's democratically-elected national Parliament that discussions should begin with the UK Government to enable an independence referendum to be held.
"Today's vote must now be respected. The mandate for a referendum is beyond question, and it would be democratically indefensible - and utterly unsustainable - to attempt to stand in the way of it.
"We will now act on the mandate given to us by Parliament by making a formal approach to the UK Government within the next few days, after Article 50 has been triggered.
"This is, first and foremost, about giving the people of Scotland a choice on this country's future.
"The Prime Minister says that now is not the time for a referendum. I agree with that, which is why I have indicated a timescale no earlier than 18 months from now, when the terms of Brexit are clear - something the PM has now indicated she agrees with.
"It is up to the UK Government to now make clear when they consider a referendum would be appropriate."
UK Scottish Secretary David Mundell told BBC Scotland: "We won't be entering into any negotiations at all until the Brexit process is complete.
"Now's the time for the Scottish Government to come together with the UK Government, work together to get the best possible deal for the UK and that will mean for Scotland as we leave the EU.
"We're not entering into negotiations on whether there should be another independence referendum during the Brexit process.
"We don't have a crystal ball as to how long that process will take. We don't recognise, for example, 18 months as being a key point in the journey.
"It will be a journey that will involve the negotiations with the EU, it may be a journey that involves transitional measures, it may be a journey that will involve significant implementation time.
"It's not appropriate to have a referendum whilst people do not know what the future relationship between the UK and the EU is and they won't know that until the Brexit process is complete."
A UK Government spokeswoman said: "The Prime Minister has been clear that now is not the time for an independence referendum, and we will not be entering into negotiations on the Scottish Government's proposal.
"At this point, all our focus should be on our negotiations with the European Union, making sure we get the right deal for the whole of the UK.
"It would be unfair to the people of Scotland to ask them to make a crucial decision without the necessary information about our future relationship with Europe, or what an independent Scotland would look like.
"We have been joined together as one country for more than 300 years. We've worked together, we've prospered together, we've fought wars together, and we have a bright future. At this crucial time we should be working together, not pulling apart."
She said: "We have made it clear: now is not the time to go back to another divisive referendum. Not when there is no public support for one. Not when the SNP said the last referendum would be once in a generation. Not when we have no clear picture as to what either Brexit or independence will look like.
"We will continue to oppose a second referendum every step of the way. The majority of people in Scotland do not want it and the SNP does not have a clear mandate to pursue it."
Ross Greer, the Scottish Greens' external affairs spokesman, said: "It should be our responsibility, as those elected by the people of Scotland, to fight for their right to choose their own future.
"Giving the people that choice in autumn of 2018 - when the details of the deal are known - would give us the time to begin extracting Scotland from this mess before the Tories hurl Britain off the hard Brexit cliff - if that is what the voters choose."
Labour and Liberal Democrat MSPs voted against the call for another referendum alongside the Tories.
Scottish Labour leader Kezia Dugdale said there is no evidence that Scots want another ballot.
She said: "There absolutely should not be another independence referendum until after Brexit. We have no idea what Brexit looks like, or how it will impact our economy and families in Scotland.
"If there is to be another vote, the people of Scotland deserve clarity on what they are being asked to vote on.
"This process cannot be a stitch-up between Nicola Sturgeon and Theresa May."
Scottish Lib Dem leader Willie Rennie said: "Scottish Liberal Democrats stood on a manifesto to oppose a divisive referendum and we will continue to do that.
"The SNP say they speak for Scotland, well they spoke three years ago and told them No. Instead of hunting for division we need to sort out the problems on our doorstep."
Scotland's Brexit Minister Mike Russell said "it's a question now of how, rather than if".
He added: "The real issue now is no-one can stand against it. It's the choice of the Scottish Parliament, it's the choice of the Scottish people, and that will be recognised globally. So what we now need to do is have a sensible discussion about how this proceeds.
"Theresa May has succeeded in creating constitutional chaos throughout the UK. I hope there will come a moment, and perhaps this is that moment, in which she recognises this is a foolish way to operate."