Skip to main content
The serve command is used to make the specified layouts available to the CTA for validation experiences. Either provide a packaged touch adaptation bundle (that’s created with the pack command), or provide a set of layouts that aren’t packaged. The following table shows the different options that are available for use with the serve command.

Security considerations

The serve command is intended for local development. It temporarily hosts touch adaptation bundles from a development PC so a streaming client can load them during iteration. It shouldn’t be exposed to the public internet.
Use the narrowest host binding that fits your scenario:
  • Use --host localhost when only the local PC needs to connect.
  • Use --host <specific IP address> when a streaming client needs to connect through one known local network interface.
  • Use --host 0.0.0.0 only when you intend to listen on every network interface on the development PC. Other devices on the same network might be able to reach the sideload server if firewall and network rules allow it.
The default HTTP listener is acceptable for a trusted local sideload session while you’re actively iterating. Tighten the configuration when you bind beyond localhost, use a shared or untrusted network, or need to leave the server reachable for longer than the current test pass. In those cases, prefer HTTPS by using --certificate-file with --certificate-password, as described in Certificate Generation Instructions. Add --password when you want to restrict client access to the served bundle.
When --password is used, choose or generate the value locally for the sideload session and enter the same value in the client’s developer settings. The password protects access to that local HTTPS sideload session; Microsoft doesn’t manage or rotate it for you. Rotate it by restarting tak serve with a new password and updating the client setting.

Examples

Use the following code example to serve a touch adaptation bundle on a host.
Serve all the layouts in the layout-path on the default port and host and declare a specific version/version name

Serve a specified touch adaptation bundle only over localhost

Certificate Generation Instructions

A certificate is required to host an authenticated secure server for sideloading Touch Bundles. Any appropriate SSL certificate can be used, but the instructions below will create a certificate as well
  1. Obtain the script to generate self-signed certificate from the XBOX Game Streaming Tools GitHub a. Navigate to the link above, select ‘raw’, and copy-paste the script contents into a document on your local machine b. Alternatively, run the following command in Powershell to download the script
The Create-SelfSignedCertificate.ps1 script only works on Windows. Tools may exist on other operating systems to generate valid self signed certificates
  1. Run the downloaded script in Powershell.
  2. The script will prompt you for a password to secure the certificate. Set the password by entering it here. This password will be used as input to the -certificate-password flag of the serve command. This will generate two files: sideload.pfx and sideload.cer. The path to the sideload.pfx certificate file is to be passed as input to the -certificate-file flag of the serve command.

Trusting the certificate on different clients

Load the .cer file onto your device. This can be accomplished via e-mail, OneDrive, USB, ADB, AirDrop etc. Trust the certificate in the usual manner appropriate for the given device.

Windows

  1. Double click the sideload.cer file
  2. Select ‘Install Certificate’. This will open Certificate Import Wizard.
  3. Select ‘Current User’ as the Store location.
  4. In the next window, select ‘Place all certificates in the following store’ then select ‘Browse for Trusted Root Certification Authorities’.

Android

  1. On your Android device, navigate to Settings > Security > Advanced > Encryption & credentials > Install from Storage.
  2. Install the certificate by selecting CA certificate and then browse for the sideload.cer file downloaded in the previous section Once installed, this certificate can be viewed under Trusted Credentials > User
See Google’s documentation for more information.

iOS

  1. Navigate to the Files application on your iOS device to install the .cer file to your device profiles
  2. A new profile should be generated based on the .cer file profile name. This can be found under Settings > General > Profiles & Device Management.
  3. Install the certificate. The certificate signature should show as verified.
  4. To test the installed certificate, navigate to Settings > General > About > Certificate Trust Settings. Enable full trust for the root certificate that was just installed.
See Apple’s documentation for more information.

Examples

Use the following code example to serve a touch adaptation bundle on a host securely.
Serve all layouts in the layout path on the default host and port over https

Serve all layouts in the layout path on the default host and port securely upon authenticating the client.

See also

Touch Adaptation Kit Command Line Tool (tak.exe)
Last modified on October 20, 2026