Skip to main content
URL match rules surface your LinkApp when creators paste URLs that look like the ones you specify. They improve discovery only—creators can still add your app manually for any other URL.
linkapp.config.ts

Define match rules

  • hostnames (required) — domains your app supports. List every variant you expect (youtube.com, www.youtube.com, m.youtube.com, etc.).
  • patterns — optional pathname/search combos that must match. Leave empty to match any path on the hostnames.
  • notPatterns — optional exclusions, useful when matching a broad path with specific carve-outs.

Pattern syntax cheatsheet

Patterns use URLPattern semantics. Paths are case-sensitive. Query parameters can appear in any order.

Test your rules

Use the CLI to confirm matches before shipping:
Positive matches print the LinkApp slug; failures show the part that missed. Add a script for quick re-testing:
package.json

Troubleshoot fast

  • Double-check hostnames—include www/mobile/regional variants explicitly.
  • Ensure named parameters keep the colon (/user/:id, not /user/id).
  • Declare query parameters with both the key and placeholder (search: "v=:videoId").
  • Replace overly broad wildcards if you see unexpected matches.

Best practices

  • Start specific, then add broader fallbacks (/watch before /:id).
  • Document uncommon paths with inline comments for future maintainers.
  • Keep the total number of patterns below the 50-pattern limit.
  • Re-run linkapp test-url-match-rules after every config change.