The length of a day -- 24 hours from sunrise to sunrise, on average -- comes mostly from Earth's rotation. But a few minutes of it comes from Earth's orbiting around the sun. It takes Earth 23 hours, 56 minutes, and a bit over 4 seconds to rotate 360 degrees, at the end of which time the stars will be in the same positions in the sky as they were the previous day. But because the sun isn't in the same place in the sky as it was the previous day, Earth has to rotate about 3 minutes and 56 seconds more to bring the sun back into the same apparent position it had been in 24 hours previously.
The catch is that "about". Two things affect this number. First, Earth's orbit isn't perfectly circular. It's closest to the sun in early January and furthest in early July. When it's further, it moves more slowly in its orbit, so it doesn't have to turn as much extra to make a day. When it's closer, it moves more quickly, so it has more to make up. Second, and right now more importantly, at the equinoxes some of the sun's apparent motion is north-south so Earth doesn't have to rotate as far to catch up to the sun's new east-west position. At the solstices, Earth has to turn quite a bit further to make up for same amount of orbital motion, because all of the sun's apparent motion is east-west. This makes the day/night cycle longer than average -- right now, it's about 24 hours 15 seconds from one sunset (or sunrise) to the next. The effect is even more pronounced in December when it's aligned with the eccentricity effect instead of opposed to it.
The longer days mean that here in Boston, though we've missed the earliest sunrise by about a week, we have until June 26 to celebrate the latest sunset of the year.