Cloud House Technologies Logo
CloudHouse Technologies
HomeServicesProjectsBlogAbout UsCareersContact UsLogin
    Cloud House Technologies Logo
    CloudHouse Technologies
    HomeServicesProjectsBlogAbout UsCareersContact UsLogin

    How to Fix VS Code Not Installing on Ubuntu Desktop: .deb Package & apt Repository Errors (2026 Guide)

    Priya

    Content Writer & Researcher

    Last Updated: 2 July 2026
    How to Fix VS Code Not Installing on Ubuntu Desktop: .deb Package & apt Repository Errors (2026 Guide)
    🖥️

    VS Code Won't Install on Ubuntu? We'll Fix It Fast

    From broken dpkg dependencies to GPG signature errors, our Linux specialists resolve stubborn Ubuntu Desktop software issues so you can get back to coding today.

    🔧 Book Free DiagnosisCall NowWhatsApp
    🖥️12,400+PCs Fixed
    ⭐4.9★Google Rating
    ⚡<15 minAvg. Response
    🛡️ISO 27001Certified

    If Visual Studio Code refuses to install on your Ubuntu Desktop machine, you're not alone. The two most common failure points are the .deb package install via dpkg throwing dependency errors, and the official Microsoft apt repository failing with GPG key or signature errors. Both issues have straightforward, permanent fixes once you understand what's actually happening under the hood — this guide walks through every real error message you'll see and exactly how to resolve it.

    Why VS Code Fails to Install on Ubuntu Desktop

    VS Code on Ubuntu can be installed three different ways: downloading the .deb file directly from code.visualstudio.com, adding Microsoft's official apt repository, or installing the Snap package. Each method fails for different reasons:

    • The .deb package can fail with dpkg: dependency problems prevent configuration when required libraries (like a specific libc6 or libgtk version) aren't present on your system.
    • The Microsoft apt repository commonly fails with NO_PUBKEY EB3E94ADBE1229CF or The following signatures couldn't be verified because newer Ubuntu releases removed the deprecated apt-key tool and require GPG keys to live in /etc/apt/keyrings/.
    • The Snap package can fail if snapd itself is broken, or the app hangs on first launch due to sandboxing restrictions.

    Below are step-by-step fixes for each scenario.

    💡 None of these worked? Skip the guesswork.

    Get Expert Help →

    Method 1: Fix .deb Package Installation Errors with dpkg and apt

    If you downloaded the .deb installer directly from the VS Code website, install it correctly the first time using apt instead of raw dpkg, since apt resolves dependencies automatically:

    1Install using apt, not dpkg directly

    Navigate to your Downloads folder and run:

    cd ~/Downloads
    sudo apt install ./code_1.96.0-1234567890_amd64.deb

    Using apt install ./file.deb (with the leading ./) tells apt to treat the local file as a package and automatically pull in any missing dependencies from your configured repositories.

    2If you already used dpkg -i and hit errors

    If you ran sudo dpkg -i code_*.deb first and saw:

    dpkg: dependency problems prevent configuration of code:
     code depends on libgtk-3-0 (>= 3.9.10); however:
     Package libgtk-3-0 is not installed.
    dpkg: error processing package code (--configure):
     dependency problems - leaving unconfigured

    Fix it by letting apt finish the job:

    sudo apt --fix-broken install
    sudo apt install -f

    This pulls in every missing dependency and re-configures the partially installed package.

    3Update your package index first if dependencies can't be found

    Sometimes the dependency simply isn't in your local package cache yet:

    sudo apt update
    sudo apt --fix-broken install
    4Cannot satisfy dependencies on newer Ubuntu releases

    On Ubuntu 26.04 and other very recent releases, you may see Error: Cannot satisfy dependencies because the .deb build expects an older library version than what's shipped. In this case, skip the standalone .deb entirely and use the apt repository method below (Method 2) or the Snap package (Method 3) instead — both are actively maintained against current Ubuntu releases, while a manually downloaded .deb is a snapshot in time.

    1Install prerequisites
    sudo apt update
    sudo apt install wget gpg
    2Import Microsoft's GPG signing key into the correct location

    Newer Ubuntu versions removed the deprecated apt-key command, so the key must be stored as a standalone file:

    wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg
    sudo install -D -o root -g root -m 644 packages.microsoft.gpg /etc/apt/keyrings/packages.microsoft.gpg
    3Add the repository with signed-by pointing to the key
    echo "deb [arch=amd64,arm64,armhf signed-by=/etc/apt/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/code stable main" | sudo tee /etc/apt/sources.list.d/vscode.list
    4Update and install
    sudo apt update
    sudo apt install code
    5Fix "NO_PUBKEY EB3E94ADBE1229CF" errors specifically

    If apt update shows:

    W: GPG error: https://packages.microsoft.com/repos/code stable InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY EB3E94ADBE1229CF

    This means an old repository entry exists without the signed-by path, or the key file is missing/corrupted. Remove any old, incorrect entries and re-run steps 2-4:

    sudo rm /etc/apt/sources.list.d/vscode.list
    sudo rm -f /etc/apt/trusted.gpg.d/microsoft*.gpg

    Then repeat the key import and repository steps above exactly. Do not mix the old apt-key add method with the new signed-by method — having both creates duplicate, conflicting key entries.

    6Fix "repository is no longer signed" errors

    If you see The repository 'https://packages.microsoft.com/... InRelease' is no longer signed, your /etc/apt/sources.list.d/vscode.list file is likely malformed or duplicated. Check for duplicate entries and remove extras:

    grep -r "packages.microsoft.com" /etc/apt/sources.list.d/
    cat /etc/apt/sources.list.d/vscode.list

    Keep only one clean line as shown in step 3, then run sudo apt update again.

    Method 3: Install VS Code via Snap as a Reliable Alternative

    If you'd rather avoid managing apt repositories and GPG keys entirely, the Snap package is officially maintained by Microsoft and sandboxed by default:

    sudo snap install code --classic

    The --classic flag is required because VS Code needs broader filesystem access than Snap's default confinement allows (for opening arbitrary project folders, running extensions, and using integrated terminals).

    Trade-offs to know before switching to Snap:

    • Snap updates are automatic but can lag a day or two behind the apt repository release.
    • First launch is often slower than the apt/deb version due to Snap's mount-based packaging.
    • Some extensions that need direct system integration (certain USB debugging tools, hardware debuggers) behave better on the apt-installed version even with --classic confinement.

    If snap install itself fails, ensure snapd is healthy first:

    sudo systemctl status snapd
    sudo systemctl restart snapd
    sudo snap install code --classic

    Fixing Common Post-Install Issues (Won't Launch, Missing Icon)

    Once installed, a few more issues commonly appear:

    VS Code icon missing from the Applications menu

    sudo update-desktop-database
    sudo gtk-update-icon-cache

    Then log out and back in, or restart GNOME Shell with Alt+F2 then r (X11 sessions only).

    VS Code launches but window is blank or crashes immediately

    This is usually a GPU/Electron rendering issue on certain NVIDIA driver combinations. Launch with hardware acceleration disabled to confirm:

    code --disable-gpu

    If that resolves it, add --disable-gpu permanently to your desktop launcher, or update your graphics drivers.

    "code: command not found" after apt install

    Your shell's PATH cache may be stale. Run hash -r or open a new terminal window — the apt-installed version places the binary in /usr/bin/code which should already be on PATH.

    When to Get Professional Linux Desktop Support

    Most VS Code installation failures on Ubuntu Desktop are resolved by the steps above, but repository conflicts, broken snapd installations, or deeper dependency chain issues (especially after a distribution upgrade) can eat hours of troubleshooting time. If you manage multiple Ubuntu workstations for a team, or you'd rather have a specialist fix it once and document it properly, CloudHouse Technologies offers pay-per-ticket Linux desktop support so you only pay for the issue you need resolved — no subscription required.

    Whether it's a stubborn .deb dependency error, a broken apt repository, or a Snap sandboxing quirk, getting VS Code running reliably on Ubuntu Desktop shouldn't take all afternoon. Use the apt repository method for long-term stability, keep an eye on GPG key locations after major Ubuntu upgrades, and fall back to Snap if you want a zero-maintenance install.

    Get the Free Linux Server Admin Cheatsheet (PDF)

    Essential commands for server management, networking, and troubleshooting — all on one printable page.

    Running Linux servers? Let us manage them for you.

    Our Managed Linux Server plans cover updates, security hardening, monitoring, and 24/7 incident response — so your servers stay up and your team stays focused.

    • Proactive OS patching and security updates
    • 24×7 monitoring with instant alerting
    • Backup configuration and disaster recovery
    • Dedicated Linux engineers on call
    See Pricing Plans →

    What our customers say

    “Our production server went down at 2 AM. CloudHouse had it back online in under 20 minutes. Incredible response time.”

    Arun S.

    CTO, SaaS Startup

    “They migrated our entire infrastructure from Ubuntu 18 to 22 with zero downtime. Couldn't have asked for better.”

    Deepak N.

    DevOps Lead

    Frequently Asked Questions

    This happens when the downloaded .deb file requires a library version (commonly libgtk-3-0 or a specific glibc version) that isn't installed or available in your current apt sources. Run sudo apt --fix-broken install right after the failed dpkg -i command to automatically pull in the missing dependencies.

    Book your free 15-minute diagnosis

    A certified technician will call you back within 15 minutes during business hours.

    Share this article

    Leave a Comment

    Comments (0)

    Loading comments...

    Struggling With VS Code Installation on Ubuntu?

    Repository conflicts and dependency errors can burn hours of your day. CloudHouse Technologies' Linux desktop support team fixes installation issues on a pay-per-ticket basis, with no subscription required.

    Call Now — FreeWhatsApp Us

    Why CloudHouse?

    • ISO 27001:2022 certified
    • 12,400+ devices supported
    • 4.9★ on Google
    • Sub-15-minute response

    CloudHouse Technologies

    Innovative cloud solutions for modern businesses. We deliver cutting-edge technology with exceptional service.

    Contact Us

    CloudHouse Technologies Pvt.Ltd
    Special Economic Zone(SEZ),
    Infopark Thirissur,4B-15,
    Indeevaram,Nalukettu Road,
    Koratty, Kerala, India-680308
    0480-27327360
    info@cloudhousetechnologies.com

    Quick Links

    • Our Services
    • Gold Loan Software
    • About Us
    • Contact
    • Terms and Conditions
    • Privacy Policy
    ISO27001:2022
    Certified

    © 2026 CloudHouse Technologies Pvt.Ltd. All rights reserved.

    Back to top