In order to edit your saves for use with save editors like PKHeX or Sky Editor, you must first be able to backup/restore your save file from a cartridge. There are many ways this can be accomplished, and it all depends on what hardware you have available. The following methods are listed in order of recommendation. Pick the first one you have the hardware to use.
When this guide refers to IR games, it refers to games with an IR port like Pokemon HeartGold, SoulSilver, Black, White, Black 2, and White 2, since older tools are not compatible with these. This can be bypassed using a hardware mod of the cartridge that is outside the scope of this guide and is generally not recommended.
Alternatively, if you use an emulator, you should already have access to your save file. However, not all emulators use a save file format that's compatible with save editors by default (such as No$GBA). This is currently outside the scope of this guide, but you're having trouble, you can ask in the comments section at the bottom of this page.
3DS with CFW
If your 3DS doesn't have CFW, check Plailect's comprehensive guide to setting up CFW to see if you're able to use this option. If you are able, follow this guide:
3DS with Homebrew and either PokéTransporter or Pokémon Dream Radar Installed
This option works with either CFW or homebrew. If CFW is not an option, check Smealum's homebrew website to see if you have a compatible homebrew entry-point. If you do not have CFW or homebrew, then you cannot use your 3DS to manage NDS saves.
If you meet these requirements, please follow this guide:
NDS Backup Adapter Plus OR SMS4 OR R4i Save Dongle. Older variants may not work on IR games.
Follow this guide for a usage guide:
Look here if you need help disabling driver signature enforcement on versions of Windows newer than Windows XP (used in the above guide).
Action Replay DSi with a Micro-SD slot and an NDS (original, lite, or DSi) OR an Action Replay Media Edition and an original DS or DS Lite. Will not work on IR games.
Not all Action Replay DSi units have a micro-SD slot. Unfortunately, neither the Action Replay DSi with the micro-SD slot nor the Action Replay Media Edition are made or sold anymore.
Please refer to the following guide for using the Action Replay DSi. The exact usage of the Action Replay Media Edition is similar but may vary slightly.
In order to allow compatibility with save editors, you may need to convert the *.duc files to raw format. My save converter can be found here. An alternative save converter written by @Matt140, with instructions written by @Scarface, can be found here. This is not required for PKHeX.
Original DS or DS Lite AND a slot 2 flashcart that can run NDS homebrew
Original DS or DS Lite AND a slot 1 flashcart AND an EZ Flash 3in1
With this hardware combo, your cartridge's save file is written to the EZ Flash 3in1, then copied to your slot 1 flashcart using @Pokedoc's savegame manager. Refer to the included PDF for usage instructions.
Original DS or DS Lite AND a slot 1 flashcart AND WEP Wi-FI AND an FTP server (your computer can function as one)
Note that WEP is different than WPA, which is more common nowadays and is much more secure.
If you cannot do any of the above, and you are not playing on a flashcart or an emulator, then you do not have access to your save file and cannot directly edit it. Depending on what you wish to do, you might be able to create Action Replay codes using PokeGen, but that is outside the scope of this guide.
Emulators (DeSmuMe, No$GBA, or Drastic)
If you're playing on an emulator instead of a console, getting your save data is far easier and requires no hardware except for a compatible computer. Read here to learn how to get your saves from certain emulators:
Edited by evandixon