How to remove DRM from Kindle with Calibre.
I use Kobo, which uses a slightly different method. Some publishers already don't use DRM. Great! You're good to go. Most others will be listed as using Adobe DRM. For that, you'll need Adobe Digital Editions.
Download the DRM file. This will be an ASCM file (Adobe Content Server Message) called 'URLLink.ascm'. This isn't an ebook, it's basically just a link.
Open in Adobe Digital Editions. It should automatically download the ebook.
Locate the actual file location. By default, this is Documents > My Digital Editions. This will give you the epub file, with DRM.
Follow the above instructions to install DeDRM in Calibre.
Drag the epub file into Calibre. If you've installed DeDRM correctly, there'll be a button up the top labelled 'Convert books'.
Up the top of the window, there'll be 'Input format' on the left, and 'Output format' on the right. Input will default to EPUB, select whatever you like (including EPUB again) for output. Select 'OK' (bottom right).
Locate your Calibre file. For me, this was Documents > Calibre. By default, books are listed in subfolders by author, then title. Open the folder for the book you converted, and you should have four files - a cover, an OPF file with metadata, your new EPUB file, and an old version with the file extension of .original_epub.
Not necessary, but I prefer to do this for organisation - you can now place the DRM-free EPUB file wherever you like. I have folders for my own library that I can back up as I wish.
You may want an ereader not tied to a particular platform. I use one for my phone called Moon+ Reader. It has a free option with unobtrusive ads (which only show when you close a book). Otherwise, using Calibre on my PC has its own epub reader.
Anyway. Not hyperbole. Microsoft closed its ebook platform in 2019 and people lost their entire libraries. Back your books up.