Setting up a newly formatted computer or migrating to a new laptop often requires hours of tedious manual software installation. Users traditionally navigate to dozens of individual websites, download setup installers, click through wizard dialogues, and decline unwanted bundled software. To automate this process, Microsoft built the Windows Package Manager (winget) into Windows 11. Beyond updating and installing individual command-line tools, winget includes powerful export and import commands. These commands allow you to capture your entire software suite into a single portable JSON manifest file and replicate the identical installation onto another Windows PC with one automated command.
Why Use winget Export and Import?
Adopting package manager manifests provides substantial operational advantages over traditional manual deployment:
- Zero-Click Batch Deployment: Installs dozens of applications sequentially in silent background mode without manual user intervention.
- Infrastructure as Code: Your software environment is codified in an editable JSON text file that can be committed to a personal GitHub dotfiles repository.
- Official and Community Sources: Pulls verified packages directly from the Microsoft Community Repository and the Microsoft Store.
- Version Pinning: The exported manifest records specific software versions, ensuring consistent configurations across developer teams.
Prerequisites and Verifying winget Installation
Windows Package Manager is included natively in Windows 11 as part of the App Installer package. To verify availability, open Windows Terminal (PowerShell or Command Prompt) and run:
winget --version
If Windows reports that winget is not recognised, open the Microsoft Store app, search for App Installer, and update it to the latest release.
Step 1: Export Installed Applications to a JSON Manifest
To scan your current computer and generate a portable configuration file, navigate to your desired directory in Windows Terminal and execute the winget export command:
winget export -o "$env:USERPROFILE\Desktop\apps_backup.json"
Windows Package Manager scans installed desktop software, cross-references each application against the official winget repository, and writes matching package IDs into the target JSON file.
Exporting Without Version Pinning (Recommended for Up-to-Date Installations)
By default, winget pins the exact version number of every application in the manifest. If you prefer your new machine to install the newest available versions of each app, add the --include-versions false flag:
winget export -o "$env:USERPROFILE\Desktop\apps_latest.json" --include-versions false
Step 2: Inspecting and Editing the Manifest File
Open the generated apps_backup.json file in Notepad or VS Code:
notepad "$env:USERPROFILE\Desktop\apps_backup.json"
The manifest contains a structured array of packages:
{
"$schema": "https://aka.ms/winget-packages.schema.2.0.json",
"CreationDate": "2026-10-21T04:15:00",
"Sources": [
{
"Packages": [
{ "PackageIdentifier": "Microsoft.VisualStudioCode" },
{ "PackageIdentifier": "Git.Git" },
{ "PackageIdentifier": "Mozilla.Firefox" },
{ "PackageIdentifier": "7zip.7zip" },
{ "PackageIdentifier": "Discord.Discord" }
],
"SourceDetails": {
"Name": "winget",
"Type": "Microsoft.PreIndexed.Package"
}
}
]
}
You can freely delete applications you no longer wish to carry over to your new setup, or manually append new PackageIdentifiers.
Step 3: Transfer the File and Import onto Your New PC
Copy the JSON manifest onto a USB flash drive, cloud storage service, or network share, and place it onto your destination Windows 11 machine.
- Open Windows Terminal as an Administrator (right-click the Start button and choose Terminal (Admin)).
- Navigate to the folder containing your manifest file.
- Execute the import command:
winget import -i ".\apps_backup.json" - If package sources prompt you to accept publisher agreements, append agreement flags to bypass interactive prompts completely:
winget import -i ".\apps_backup.json" --accept-package-agreements --accept-source-agreements
winget automatically downloads the latest installers from certified distribution CDNs, installs each program silently in the background, and outputs an installation summary report upon completion.
Troubleshooting Unrecognised Packages
If certain proprietary enterprise utilities or niche tools were installed from manual portable ZIP files or private corporate installers, winget export will display a notice stating that those apps lack public package definitions. These applications must still be migrated manually or packaged into custom internal winget sources.