Windows-Version und Support-Ende anzeigen
Zeigt Edition, Version (z. B. 25H2), Build, Architektur und Aktivierungsstatus – und bis wann diese Windows-Version noch Sicherheitsupdates bekommt. Erkennt Windows 10 und 11, LTSC und Windows Server. Ergebnis kopieren oder auf dem Desktop speichern. Ändert nichts am System.
SHA-256:
0329e96c5df278d2e40586c4f67a73e15f943481a51df46f96fcbf45d908a9f9 Code
So sieht die Datei aus, die Sie herunterladen (136 Zeilen). Die Kommentare oben im Skript erklären, was es tut.
<# : Friederich-IT - Windows-Version ermitteln
@echo off
setlocal
chcp 65001 >nul
title Windows-Version ermitteln - Friederich-IT
set "FIT_SELF=%~f0"
powershell -NoLogo -NoProfile -ExecutionPolicy Bypass -Command "iex ([IO.File]::ReadAllText($env:FIT_SELF,[Text.Encoding]::UTF8))"
exit /b %errorlevel%
#>
# ==========================================================================
# Windows-Version ermitteln Version 2.0, Oktober 2026
# https://friederich-it.de/downloads
#
# Zeigt Windows 10/11/Server mit Edition, Feature-Update (z. B. 25H2),
# Build, Architektur, Lizenzstatus und ob die Version noch Sicherheits-
# updates bekommt (Stand der Tabelle: Oktober 2026).
# Ändert nichts am System. Läuft ohne Administratorrechte.
# Start per Doppelklick. Die Datei ist Batch und PowerShell in einem.
# ==========================================================================
$ErrorActionPreference = 'SilentlyContinue'
try { [Console]::OutputEncoding = [Text.Encoding]::UTF8 } catch {}
function Get-SupportInfo([int]$build, [string]$type, [string]$edition) {
# Rückgabe: @(Enddatum oder $null, Text). Quelle: Microsoft Lifecycle / Release Health, Stand 10/2026
$ent = $edition -match '^(Enterprise|Education|IoTEnterprise)(N|K)?$'
$ltsc = $edition -match 'EnterpriseS|IoTEnterpriseS'
$iot = $edition -match '^IoT'
if ($type -ne 'Client') {
switch ($build) {
14393 { return @([datetime]'2027-01-12', 'Windows Server 2016') }
17763 { return @([datetime]'2029-01-09', 'Windows Server 2019') }
20348 { return @([datetime]'2031-10-14', 'Windows Server 2022') }
26100 { return @([datetime]'2034-11-14', 'Windows Server 2025') }
}
if ($build -lt 14393) { return @([datetime]'2023-10-10', 'Windows Server 2012 R2 oder älter') }
return @($null, 'Server-Version neuer als diese Tabelle')
}
if ($ltsc) {
switch ($build) {
26100 { if ($iot) { return @([datetime]'2034-10-10', 'LTSC 2024 (IoT)') } else { return @([datetime]'2029-10-09', 'LTSC 2024') } }
19044 { if ($iot) { return @([datetime]'2032-01-13', 'LTSC 2021 (IoT)') } else { return @([datetime]'2027-01-12', 'LTSC 2021') } }
17763 { return @([datetime]'2029-01-09', 'LTSC 2019') }
14393 { return @([datetime]'2026-10-13', 'LTSB 2016') }
}
}
switch ($build) {
28000 { if ($ent) { return @([datetime]'2029-03-13', '26H1') } else { return @([datetime]'2028-03-14', '26H1') } }
26300 { if ($ent) { return @([datetime]'2029-10-09', '26H2') } else { return @([datetime]'2028-10-10', '26H2') } }
26200 { if ($ent) { return @([datetime]'2028-10-10', '25H2') } else { return @([datetime]'2027-10-12', '25H2') } }
26100 { if ($ent) { return @([datetime]'2027-10-12', '24H2') } else { return @([datetime]'2026-10-13', '24H2') } }
22631 { if ($ent) { return @([datetime]'2026-11-10', '23H2') } else { return @([datetime]'2025-11-11', '23H2') } }
22621 { if ($ent) { return @([datetime]'2025-10-14', '22H2') } else { return @([datetime]'2024-10-08', '22H2') } }
22000 { if ($ent) { return @([datetime]'2024-10-08', '21H2') } else { return @([datetime]'2023-10-10', '21H2') } }
19045 { return @([datetime]'2025-10-14', 'Windows 10 22H2') }
}
if ($build -gt 28000) { return @($null, 'neuer als diese Tabelle') }
if ($build -lt 22000) { return @([datetime]'1900-01-01', 'ältere Windows-Version') }
return @($null, 'unbekannt')
}
$cv = Get-ItemProperty 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion'
$os = Get-CimInstance Win32_OperatingSystem
$build = [int]$cv.CurrentBuildNumber
$ubr = $cv.UBR
$type = if ($cv.InstallationType) { [string]$cv.InstallationType } else { 'Client' }
$edition = [string]$cv.EditionID
$feature = if ($cv.DisplayVersion) { $cv.DisplayVersion } else { $cv.ReleaseId }
$name = if ($os.Caption) { $os.Caption -replace '^Microsoft\s+', '' } else { [string]$cv.ProductName }
if ($type -eq 'Client' -and $build -ge 22000) { $name = $name -replace 'Windows 10', 'Windows 11' }
$arch = switch ($env:PROCESSOR_ARCHITECTURE) { 'AMD64' { '64 Bit (x64)' } 'ARM64' { '64 Bit (ARM)' } 'x86' { if ($env:PROCESSOR_ARCHITEW6432) { '64 Bit (32-Bit-Shell)' } else { '32 Bit' } } default { $env:PROCESSOR_ARCHITECTURE } }
$typText = switch ($type) { 'Client' { 'Arbeitsplatz' } 'Server' { 'Server mit Desktop' } 'Server Core' { 'Server Core (ohne Desktop)' } default { $type } }
$lizenz = 'unbekannt'
$lp = Get-CimInstance SoftwareLicensingProduct -Filter "ApplicationID='55c92734-d682-4d71-983e-d6ec3f16059f' AND PartialProductKey IS NOT NULL" | Select-Object -First 1
if ($lp) {
$lizenz = switch ([int]$lp.LicenseStatus) { 0 { 'nicht lizenziert' } 1 { 'aktiviert' } 2 { 'Testphase (nicht aktiviert)' } 3 { 'Testphase abgelaufen' } 4 { 'Nachfrist (Echtheit)' } 5 { 'nicht aktiviert (Hinweismodus)' } 6 { 'verlängerte Testphase' } default { 'unbekannt' } }
if ($lp.Description -match 'TIMEBASED_EVAL') { $lizenz = 'Evaluierungsversion' + $(if ($lp.EvaluationEndDate -and $lp.EvaluationEndDate.Year -gt 2000) { ' bis ' + $lp.EvaluationEndDate.ToString('dd.MM.yyyy') } else { '' }) }
}
$sup = Get-SupportInfo $build $type $edition
$heute = Get-Date
if ($sup[0]) {
$tage = [int]($sup[0] - $heute).TotalDays
if ($tage -ge 0) { $supText = "ja, bis $($sup[0].ToString('dd.MM.yyyy')) (noch $tage Tage)"; $supFarbe = if ($tage -lt 120) { 'Yellow' } else { 'Green' } }
elseif ($sup[0].Year -lt 2000) { $supText = "NEIN – $($sup[1]), schon lange ohne Updates"; $supFarbe = 'Red' }
else { $supText = "NEIN – Updates endeten am $($sup[0].ToString('dd.MM.yyyy'))"; $supFarbe = 'Red' }
} else { $supText = "keine Angabe ($($sup[1]))"; $supFarbe = 'Gray' }
$boot = $os.LastBootUpTime
$laufzeit = if ($boot) { $d = $heute - $boot; '{0} Tage, {1} Std., {2} Min.' -f $d.Days, $d.Hours, $d.Minutes } else { '' }
$zeilen = [ordered]@{
'Windows' = $name
'Feature-Update' = $(if ($feature) { $feature } else { '–' })
'Build' = "$build.$ubr"
'Edition (ID)' = $edition
'Art' = $typText
'Architektur' = $arch
'Lizenz' = $lizenz
'Installiert am' = $(if ($os.InstallDate) { $os.InstallDate.ToString('dd.MM.yyyy') } else { '' })
'Letzter Neustart' = $(if ($boot) { $boot.ToString('dd.MM.yyyy HH:mm') + " (vor $laufzeit)" } else { '' })
'Computername' = $env:COMPUTERNAME
'Sicherheitsupdates' = $supText
}
Write-Host ''
Write-Host ' Windows-Version' -ForegroundColor Cyan
Write-Host ' ===============' -ForegroundColor Cyan
foreach ($k in $zeilen.Keys) {
Write-Host (' {0,-19}' -f ($k + ':')) -NoNewline
if ($k -eq 'Sicherheitsupdates') { Write-Host $zeilen[$k] -ForegroundColor $supFarbe } else { Write-Host $zeilen[$k] }
}
Write-Host ''
if ($type -eq 'Client' -and $build -lt 22000) {
Write-Host ' Hinweis: Windows 10 bekommt seit dem 14.10.2025 keine kostenlosen Sicherheitsupdates mehr.' -ForegroundColor Yellow
Write-Host ' Ob der PC Windows 11 kann, prüft das Skript "windows11-check.cmd" von friederich-it.de.' -ForegroundColor Yellow
Write-Host ''
} elseif ($sup[0] -and $sup[0] -lt $heute) {
Write-Host ' Tipp: Über Einstellungen > Windows Update auf die neueste Windows-Version aktualisieren.' -ForegroundColor Yellow
Write-Host ''
}
$bericht = ($zeilen.Keys | ForEach-Object { '{0,-19} {1}' -f ($_ + ':'), $zeilen[$_] }) -join "`r`n"
$bericht = "Windows-Version ($(Get-Date -Format 'dd.MM.yyyy HH:mm'))`r`n" + $bericht
while ($true) {
Write-Host ' [K] Kopieren [S] Als Textdatei auf dem Desktop speichern [Enter] Beenden' -ForegroundColor DarkGray
$t = [Console]::ReadKey($true)
if ($t.Key -eq 'Enter' -or $t.Key -eq 'Escape') { break }
if ($t.KeyChar -in 'k','K') { Set-Clipboard -Value $bericht; Write-Host ' In die Zwischenablage kopiert.' -ForegroundColor Green }
if ($t.KeyChar -in 's','S') {
$datei = Join-Path ([Environment]::GetFolderPath('Desktop')) ("Windows-Version_{0}.txt" -f (Get-Date -Format 'yyyy-MM-dd_HHmm'))
[IO.File]::WriteAllText($datei, $bericht, [Text.Encoding]::UTF8)
Write-Host " Gespeichert: $datei" -ForegroundColor Green
}
}