About a week.
At the beginning of Agents of SHIELD s02e20 “Scars”, Coulson says:
What's transpired over the last week is a lot to take in.
Given the matter of fact tone in which Ultron’s defeat and Theta Protocol (the deployment of a repaired Helicarrier) is discussed, we can deduce that the events of Age of Ultron have concluded before this episode airs.
At the end of s02e19 “The Dirty Half Dozen”, we see
Coulson and Maria Hill discuss the location of Loki’s sceptre in Sokovia, and the then-unexplained Theta Protocol. Since Age of Ultron begins with the Avenger’s storming the stronghold in Sokovia for the sceptre, it follows that this episode ends before the film begins.
Coulson is only interested in the threat posed by Ultron, not what the Avengers get up to afterward. It’s possible and likely that some of the scenes at the end of the film (including the scene with Hawkeye’s baby) take place after this week has finished. So most of the film is covered in a week, but it might stretch longer than that.
In an interview with the Empire podcast, Joss Whedon was asked when the scene with Hawkeye’s baby took place. (About the 28 minute mark) According to him, it’s at least a few months.