A few stations north and west (subway) with nearby hotels, but outside the Boston/Cambridge "in-town" areas include:
Alewife (Red Line) - AC Hotel by Marriott, Freepoint, and Homewood Suites all within a 15-20 minute walk.
Sullivan (Orange Line) - Holiday Inn on Washington Street
Assembly (Orange) - La Quinta
Wellington (Orange) - AC Hotel (Marriott) at Station Landing
There are also several hotels on O'Brien Highway (Route 28) a few blocks from Lechmere on the Green Line (Fairfield, Hampton Inn, Holiday Inn) in East Cambridge - these are sometimes slightly cheaper (though often not).
Those are a few of the places I'd check if I'm looking to stay a little outside of the downtown-ish areas but still have access to the subway.
I can't stress enough to any visitors from overseas that our commuter rail system is very, very limited off-peak and weekends. If you plan to use it, you need to plan your day around its schedule, not vice-versa. Most lines have very few round trips (6-8 total) on weekends. The best weekend frequencies are usually about once every two hours on the "good" lines!
Wondering if I'll see the Western Route double-tracking finished before I retire...
Photo: Melbourne W7 No. 1019 on Route 78, Bridge & Church Streets, Richmond, Victoria. 10/21/2010