The premiere is being tipped as one of the festival's highlights
The Edinburgh International Film Festival will host the international premiere of Toy Story 3 the day after it is first screened in the US.
The film festival, now in its 64th year, will show the film on Saturday 19 June, a full month before it goes on general release in the UK.
The special 3D gala will celebrate the 15th anniversary of Woody and Buzz Lightyear's big screen debut.
The original Toy Story was the first feature-length CG animation film.
Hannah McGill, artistic director at the Edinburgh International Film Festival (EIFF), said: "To have the first screening after it's unveiled in the US is an incredible honour for us.
"This is going to be one of the highlights of the festival, and I'm looking forward to working with our friends at Disney to make it truly spectacular."
The gala builds on Disney's relationship with the EIFF, which has premiered their productions such as Wall-e and Ratatouille in previous years.
In the upcoming film Andy's toys face an unpredictable future and have to make sure "no toy gets left behind" as Andy heads off to college.
The voices of Tom Hanks, Tim Allen and Joan Cusack will be reunited under the direction of Lee Unrich, whose previous credits include Monsters Inc and Finding Nemo.
Newcomers to the team of the toys' voices will include Timothy Dalton as Mr Picklepants and Michael Keaton as Ken.