Ardrossan is to continue to be the mainland port for the Arran ferry service.
The Scottish government made the decision after considering responses to a report on a possible switch to Troon.
The operators of Troon, Associated British Ports (ABP), had argued that it was a better location.
North Ayrshire Council chief executive Elma Murray said the government had made the "right decision" for local residents and the travelling public.
Investment plans were drawn up for Ardrossan Harbour in its bid to retain the year-round Arran ferry service.
The new proposals involve Ardrossan harbour owners Peel Ports investing in "significant infrastructure upgrades" at the site - including improvements to harbour walls, bollards, gantries, fenders and signage.
North Ayrshire Council is also to make improvements to the passenger terminal, roads, car park and connectivity with the town centre.
ABP had announced plans to invest £8m on a new passenger ferry terminal at Troon if it picked up the Arran service.
Proposals put forward to the Scottish government included a new Arran Community Fund, which would generate £50,000 a year for good causes.
ABP had claimed that the existing service from Ardrossan is "dogged by weather conditions that frequently exceed the capabilities of the port and result in a significant level of service cancellations".
It also claimed the Port of Troon was already well equipped to handle the next generation of Calmac ferries.
Making the announcement, Economy Secretary Keith Brown said: "Having considered all the evidence and representations, we have decided that retaining Ardrossan as the mainland port for the Arran ferry service is the best option.
"The study looked at the options under four broad pillars: connectivity, reliability, overall operational cost to the public purse and socio-economic considerations."
He said the decision followed a consultation with various groups, including those on Arran who depend on the transport link.
Ms Murray said: "Without doubt, the minister has reached the right decision following lengthy and detailed consideration of the technical data gathered during the assessment of both mainland berthing options.
"Today's announcement will reassure Arran residents and the wider travelling public that Ardrossan genuinely offers the best location for the new generation ferry being introduced in 2018."
Peel Ports project director Doug Coleman added: "We were always convinced that the benefits of retaining the ferry service on the shortest, fastest and cheapest route were overwhelming.
"Now that we have been given a long-term commitment by the Scottish government, we are able to start on the biggest investment programme Ardrossan Harbour has seen in recent years."