updated about 1 month ago
If you have a Code Snippets export file from a WordPress site, then you can import them into a different site (or the same site) using the Import Snippets menu.
To import your snippets, click on the Choose files button and select the .json or .xml file for upload. Please note that the file must be in the correct format generated from exporting snippets; you cannot upload .php files and have the content imported as snippets.
Above this section you can select what happens if the file contains snippets with the same name as snippets already existing on the site. You can choose to not check for duplicate snippets and just import everything from the file, to replace any duplicate snippets on the site with the new ones from the export file, or to skip any duplicate snippets in the export file and only import unique snippets.
Regardless of whether the snippets were active on the previous site, imported snippets are always inactive until activated using the Snippets page.