I live on the second floor of a noisy NYC apartment building, and my bedroom window is unfortunately right above a busy street. I've been sleeping with earplugs for a while, but I still get woken up. Is there any way to temporarily soundproof my window? Preferably it would be cheap and easy to install/remove.
Start by sealing any cracks with weatherstripping. Then I'd suggest investing in some heavy curtains. You can also try hanging acoustical panels on the wall (either build them yourself, or find somewhere that supplies home theater systems).
If you have single pane glass, which transmits a lot of sound, and heavy curtains (as suggested by BMitch) don't do enough, you could try making a panel from 2" sheathing foam (it comes in 2"x2'x8' pieces for about $17/piece; it may be pink or blue depending on brand). Cut it to fill the inside of the window frame (you can use a sharp utility knife and a straightedge; make several cuts of increasing depth). Paint with latex paint to go with your decor and to protect the outward-facing side from UV. This would be light weight enough to easily put into place and could be slid under a sofa or bed when you don't need it in the window.
If your window is more than 2' wide, it's a bit more of a project; you'd need to get foam-safe construction glue (it will specifically mention that it's safe for foam) and glue the tounge and groove sides together, and add some thin strips of wood cross-ways (ideally on both sides) to stiffen it.
Foam might help you, but it only kill reverberations inside the room. Dual-paned glass would probably be most effective.