- All domains are supported.
- CNAME flattening is supported. CNAME flattening speeds up CNAME resolution and allows you to use a CNAME record at your root/apex domain.
- If your DNS provider does not support CNAME flattening, you need to create an ALIAS on your root domain (named
@
or with an empty name) instead of a CNAME.
How to add a custom domain to a function
Each function comes with an automatically generated domain on which it is available. However, it is possible to assign your own domain name to make it easier to use your functions.
Before you start
To complete the actions presented below, you must have:
-
A Scaleway account logged into the console
-
Owner status or IAM permissions allowing you to perform actions in the intended Organization
-
A Serverless Function that is running
-
A domain name
If you are using Cloudflare DNS, refer to the section below.
-
On your domain provider’s platform (for example, Scaleway’s domains), add a CNAME record pointing to your function default URL in the domain’s DNS zone file.
Note -
Click the Endpoints tab on your functions’ page.
-
Click + Add endpoint.
-
Enter your custom domain name and click Add endpoint to validate the form.
-
The console runs checks on the CNAME and TLS configuration of the custom domain name. Connect to your function using your custom domain once all checks have completed.
Custom Domains do not currently support websockets. If you need to use websockets, you must configure them with the original function URL.