If Escape feels slow in Vim inside tmux, tmux is waiting to see whether more keys follow.
set -s escape-time 10
The default wait is half a second, which is long enough to notice when you press Escape to leave insert mode. Ten milliseconds is short enough to feel instant and long enough for most local terminals.
Over a slow SSH connection a very small value can mix up escape sequences, for example arrow keys that are read as Escape followed by letters. If that happens, raise the number until it stops.
It is a server option, so it needs -s, not -g. Reload the config and it applies to the whole server.
Try it without risk: start a throwaway session with tmux new -s scratch, use the shortcut or command above there, look at what changes, and close it again with tmux kill-session -t scratch.
Further reading: tmux manual page (OpenBSD, official), tmux wiki: Getting Started (official)