# Error 4700 Invalid Redirect on every new OAuth app

**URL:** <https://devforum.zoom.us/t/error-4700-invalid-redirect-on-every-new-oauth-app/144596>\
**Category:** API and Webhooks\
**Created:** [July 5, 2026, 1:01am UTC](https://devforum.zoom.us/t/error-4700-invalid-redirect-on-every-new-oauth-app/144596 "2026-07-05T01:01:52Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![LenCole](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/lencole/32/75348_2.png) [@LenCole](https://devforum.zoom.us/u/LenCole)\
**Post date:** [July 5, 2026, 1:01am UTC](https://devforum.zoom.us/t/error-4700-invalid-redirect-on-every-new-oauth-app/144596/1 "2026-07-05T01:01:52Z")

</div>

### Error 4700 Invalid Redirect on every new OAuth app

### redirect URL confirmed saved correctly

### reproduced with Zoom’s own ‘Add app now’ generated authorization URL across 3 separate apps.

Client ID is ESe9Pb6wRT6w\_asE76cKWA

---

<div class="post-metadata">

**Author:** ![chunsiong.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/chunsiong.zoom/32/35488_2.png) [@chunsiong.zoom](https://devforum.zoom.us/u/chunsiong.zoom)\
**Post date:** [July 6, 2026, 3:20am UTC](https://devforum.zoom.us/t/error-4700-invalid-redirect-on-every-new-oauth-app/144596/2 "2026-07-06T03:20:13Z")

</div>

@LenCole localhost is not a supported for redirect URL.

---

<div class="post-metadata">

**Author:** ![freelancer.nak](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/freelancer.nak/32/40968_2.png) [@freelancer.nak](https://devforum.zoom.us/u/freelancer.nak)\
**Post date:** [July 6, 2026, 2:20pm UTC](https://devforum.zoom.us/t/error-4700-invalid-redirect-on-every-new-oauth-app/144596/3 "2026-07-06T14:20:01Z")

</div>

@LenCole Hi,

As already mentioned by @chunsiong.zoom, `localhost` isn’t supported for redirect URLs - you either use your staging/development environment’s redirect URL (the simplest option if you already have one deployed), or create a local domain via `/etc/hosts` (or the Windows hosts file), e.g. `yourdomain.dev`, pointed at whatever port your app runs on locally.

I’m sharing my whole nginx config above just for reference, but you really only need a simple sample. Below is a minimal example using `yourdomain.dev`, plus the `openssl` command to generate a self-signed cert with a proper SAN (subjectAltName), and how to trust it locally so browsers don’t complain.

### 0. Which option should you use?

- **Already have a staging/dev URL?** Just use that as your redirect URL - no local setup needed, skip everything below.
- **No staging env, or want to test fully locally?** Follow the steps below to map a `.dev` domain to your local app.

### 1. Hosts file mapping

**macOS / Linux** - edit `/etc/hosts` (needs `sudo`):

```auto
##
# Host Database
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost

127.0.0.1 yourdomain.dev
127.0.0.1 api.yourdomain.dev
127.0.0.1 admin.yourdomain.dev

```

Apply on Linux (usually not needed, but flush DNS cache just in case):

```auto
sudo systemd-resolve --flush-caches # or
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder # macOS

```

**Windows** - edit `C:\Windows\System32\drivers\etc\hosts` as Administrator (Notepad “Run as administrator”):

```auto
127.0.0.1 localhost
127.0.0.1 yourdomain.dev
127.0.0.1 api.yourdomain.dev
127.0.0.1 admin.yourdomain.dev

```

Then flush DNS:

```auto
ipconfig /flushdns

```

Note: the hosts file only maps the _domain_ to `127.0.0.1` - it doesn’t know about ports. Your app still runs on whatever port it normally does (e.g. `3000`, `8080`, `5173`, etc.). That’s what nginx is for below - it listens on the standard ports (`80`/`443`) for `yourdomain.dev` and reverse-proxies to your actual local port, so you don’t need `yourdomain.dev:3000` in the URL.

### 2. Generate a self-signed cert with SAN

Modern browsers reject certs that only set `CN` - you need `subjectAltName` (SAN). Example:

```auto
openssl req -x509 -nodes -days 365 -newkey rsa:2048 \
  -keyout yourdomain.dev.key \
  -out yourdomain.dev.crt \
  -subj "/C=US/ST=Florida/L=Saint Petersburg/O=YourCompany, Inc./OU=IT/CN=yourdomain.dev" \
  -addext "subjectAltName=DNS:yourdomain.dev,DNS:*.yourdomain.dev,DNS:api.yourdomain.dev,DNS:admin.yourdomain.dev"

```

Key points:

- `-addext "subjectAltName=..."` - list every hostname you’ll hit in the browser (including wildcard if you want one cert for all subdomains).
- Quotes must be straight quotes (`"`), not smart quotes - copy/pasting from some editors/forums can silently corrupt the `-subj`/`-addext` strings and cause a cryptic OpenSSL error.

### 3. nginx config sample

Replace `3000` below with whatever port your app actually runs on locally (Next.js dev server, Vite, Express, etc.):

```auto
server {
    listen 443 ssl;
    server_name yourdomain.dev api.yourdomain.dev admin.yourdomain.dev;

    ssl_certificate /path/to/yourdomain.dev.crt;
    ssl_certificate_key /path/to/yourdomain.dev.key;

    ssl_protocols TLSv1.2 TLSv1.3;
    ssl_ciphers HIGH:!aNULL:!MD5;

    location / {
        proxy_pass http://127.0.0.1:3000; # <-- your app's local port
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto https;
    }
}

server {
    listen 80;
    server_name yourdomain.dev api.yourdomain.dev admin.yourdomain.dev;
    return 301 https://$host$request_uri;
}

```

If your app talks to a separate API on a different port, add another `server_name` block (e.g. `api.yourdomain.dev`) pointing `proxy_pass` at that port instead, same pattern as in my full config above.

### 4. Trust the cert locally (so the browser doesn’t warn)

**macOS:**

```auto
sudo security add-trusted-cert -d -r trustRoot \
  -k /Library/Keychains/System.keychain yourdomain.dev.crt

```

**Windows** (PowerShell as Administrator):

```auto
Import-Certificate -FilePath "yourdomain.dev.crt" -CertStoreLocation Cert:\LocalMachine\Root

```

**Linux (Ubuntu/Debian):**

```auto
sudo cp yourdomain.dev.crt /usr/local/share/ca-certificates/yourdomain.dev.crt
sudo update-ca-certificates

```

After that, restart your browser (some browsers, like Chrome, also need you to restart the whole app, not just close the tab) and `https://yourdomain.dev` should load without any certificate warning, and you can use that as your redirect URL.

Thanks,  
Naeem Ahmed

> **[SimuLive - SimuLive | Automate Your Webinars & Meetings](https://simulive.us)**
>
> SimuLive turns prerecorded videos into live quality simulive webinars and meetings, with chat simulation and virtual participants no other platform offers.

---

<div class="post-metadata">

**Author:** ![seidnerj](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/seidnerj/32/72130_2.png) [@seidnerj](https://devforum.zoom.us/u/seidnerj)\
**Post date:** [July 8, 2026, 4:50pm UTC](https://devforum.zoom.us/t/error-4700-invalid-redirect-on-every-new-oauth-app/144596/4 "2026-07-08T16:50:26Z")

</div>

It did before, why are you makes such changes without providing notice? you broke a several of our apps.
