This summer as I study abroad at the University of Cambridge, having a home-base close to London has been extremely convenient! I have never been to the UK, so this was a great time to take weekend and day trips to many new places.
My main suggestion is, if you’re in the UK for a few weeks (in my case, 8 weeks), I would highly recommend getting a BritRail Pass. There are many different formats, for example my pass was a 15-day non-consecutive use pass (within 2 months). So this covered all of my weekend trips, and a few trips to London within the week. It was around $315, but was well worth it!! I definitely spent a lot less than I would have on all of my trips combined. Every trip I took would have cost approixmately $550. Plus, this pass allows for SO much flexibility, as you don’t have to book trips in advance, you can simply show your pass at the gates of any train station within Great Britain, and this will allow for unlimited travel for the day marked.
There are also passes for 8 (or fewer) days, and there are passes that are only within Scotland, Wales, England, etc. Refer to the website for all details: https://www.britrail.net