The only 100% legal and safe method is buying a legitimate Windows 11 product key or digital license.
If you are having issues with a valid license, utilize the built-in Windows Activation troubleshooter . Conclusion
Microsoft allows anyone to download and install Windows 11 directly from the Official Microsoft Download Mirror for free. If you do not enter a product key, Windows 11 will still function normally with only minor restrictions: