Amazon holiday deals See deals →ad

Mets Minor League Blog

Music theory, instruments and musicians

Mets Minor League Blog

Music theory, instruments and musicians

Enable SMB in Windows 11 with PowerShell

To enable SMB in Windows 11 with PowerShell, open PowerShell as an administrator and install only the SMB feature your task requires. For ordinary file sharing, SMB 2 and SMB 3 are the relevant modern protocols; avoid enabling SMB 1, which is an obsolete, insecure compatibility feature.

What “enable SMB” means in Windows 11

SMB (Server Message Block) is the network protocol Windows uses for shared folders, printers, and some storage services. The phrase “enable SMB” can mean different things: installing an optional SMB component, allowing a computer to host shares, connecting to a share on another computer, or permitting SMB traffic through Windows Firewall. These are separate settings, so installing a feature alone does not necessarily make a share reachable.

Windows 11 uses SMB 2 and SMB 3 for current file-sharing connections. These versions are normally available without installing the old SMB 1 feature. In most home and workplace setups, you should configure a share and network access rather than turn on SMB 1.

Check SMB features before changing them

Run Windows PowerShell as administrator. Search for PowerShell in Start, right-click it, and choose Run as administrator. To inspect optional SMB components, use:

Get-WindowsOptionalFeature -Online -FeatureName SMB1Protocol*

The wildcard can return the SMB 1 feature and its subfeatures. To check whether the SMB 1 server component is installed, you can also run:

Get-WindowsOptionalFeature -Online -FeatureName SMB1Protocol-Server

For SMB 2 and SMB 3 server settings, use the SMB PowerShell cmdlet:

Get-SmbServerConfiguration | Select-Object EnableSMB2Protocol

On Windows, the EnableSMB2Protocol setting covers SMB 2 and SMB 3. A result of True means the SMB 2/3 server protocol is enabled. This checks the server side—the ability to accept incoming SMB connections—not whether a particular folder is shared or accessible.

Enable the SMB 2/3 server protocol

If you have confirmed that the SMB 2/3 server protocol was disabled and need this PC to accept connections, enable it from elevated PowerShell:

Set-SmbServerConfiguration -EnableSMB2Protocol $true

PowerShell may ask you to confirm the change. Enter Y if you want to proceed. Check the setting afterward:

Get-SmbServerConfiguration | Select-Object EnableSMB2Protocol

This does not create a shared folder, assign permissions, or guarantee firewall access. To share a folder, use Windows’ folder-sharing controls or the New-SmbShare cmdlet, and grant access only to the intended users. For example, administrators can create a share with a command such as:

New-SmbShare -Name "Projects" -Path "C:\Projects" -ChangeAccess "CONTOSO\Alex"

Replace the example path and account with real values on your computer. The account also needs suitable permissions on the underlying folder; share permissions and file-system permissions work together.

Allow file sharing through the firewall

For a computer hosting a share, Windows Firewall must allow the appropriate file-sharing traffic on the network profile in use. First check the firewall rules:

Get-NetFirewallRule -DisplayGroup "File and Printer Sharing"

On an English-language Windows installation, you can enable the group for the Private profile with:

Set-NetFirewallRule -DisplayGroup "File and Printer Sharing" -Profile Private -Enabled True

Use this only on a network you trust. Do not enable file sharing on a public Wi-Fi profile just to make a connection work. Rule group names may be localized on non-English Windows installations, so the English display-group command may not find the rules there. Windows’ Advanced Firewall settings provide another way to select the relevant rules and profile.

To connect to a share hosted by another computer, the SMB client is generally already available. In File Explorer, enter a path such as \\PC-NAME\Projects, or map it as a drive. If you are troubleshooting a connection, check the remote computer’s share, credentials, firewall, and network reachability rather than installing SMB 1 by default.

Why SMB 1 is different—and usually should stay off

SMB 1 is a legacy protocol used by some old devices and software. It lacks important protections available in newer SMB versions and has been associated with serious security risks. Microsoft recommends removing or not installing SMB 1 where it is not required. Enabling it to solve a vague “network share not found” error can expose the computer unnecessarily and may not address the real cause.

If an older network-attached storage device or appliance genuinely requires SMB 1, first check whether its firmware or configuration can be updated to support SMB 2 or later. If there is no alternative, limit the exception to the specific device and trusted network, and turn SMB 1 off again when it is no longer needed. Do not expose SMB services to the public internet.

Windows optional-feature commands for SMB 1 vary by component and Windows version. To enable the SMB 1 server feature, the relevant command is typically:

Enable-WindowsOptionalFeature -Online -FeatureName SMB1Protocol-Server

That command is not needed for normal SMB 2/3 sharing. Installing or enabling an SMB 1 component may require a restart; follow the prompt and verify the feature state afterward. Be precise about whether you need an SMB 1 client or server: the client connects to older shares, while the server lets other devices connect to this PC using SMB 1.

Common problems and safe troubleshooting

  • Access is denied: Confirm that you are using an account authorized for the share and that both share permissions and folder permissions allow the requested action.
  • The network path cannot be found: Check the computer name or address, confirm both devices can reach each other, and verify that the host has an active share and the correct firewall rules.
  • The command is not recognized: Use Windows PowerShell with administrator rights. Some SMB cmdlets and optional-feature commands are unavailable in other shells or may differ by Windows edition and installed components.
  • SMB 2/3 reports disabled: Enable it with Set-SmbServerConfiguration only if the PC needs to host SMB shares. A client-only connection may not require changing the server setting.
  • An old device still will not connect: Check the device’s SMB version and firmware first. Do not assume that SMB 1 is the only cause; authentication settings, name resolution, and firewall rules can also prevent access.

For a quick check of active SMB connections and shares, use Get-SmbConnection and Get-SmbShare. These help distinguish a protocol setting from a missing share or an unsuccessful connection.

Frequently Asked Questions

Is SMB enabled by default in Windows 11?
SMB 2/3 support is normally available, but whether this PC accepts incoming connections depends on its server configuration, shares, permissions, and firewall. Check Get-SmbServerConfiguration rather than assuming every part of file sharing is enabled.

Do I need to enable SMB 1 to share files?
No. Current Windows file sharing normally uses SMB 2 or SMB 3. Enable SMB 1 only when a specific legacy device or application requires it and no safer alternative is available.

Does enabling SMB 2/3 create a shared folder?
No. It enables the server protocol, not a share. You must separately select a folder, configure its share and file-system permissions, and allow network traffic through the appropriate firewall profile.

How do I disable SMB 2/3 server support again?
In elevated PowerShell, run Set-SmbServerConfiguration -EnableSMB2Protocol $false. This prevents the PC from serving SMB 2/3 connections and can break incoming file-sharing access, so do not run it unless you have a specific reason.

Can I enable SMB from Windows Settings instead?
You can manage folder sharing and network discovery through Windows settings and File Explorer. SMB 1, when truly required, is an optional Windows feature; PowerShell is one way to manage it. These interfaces do not make SMB 1 advisable or necessary for modern sharing.

Enable SMB in Windows 11 with PowerShell
Scroll to top