Regular Expression To Match ZIP Archive File Path

Category: URI

A regular expression to match a ZIP archive file path.

/((\/|\\|\/\/|https?:\\\\|https?:\/\/)[a-z0-9\[email protected]\-^!#$%&+={}.\/\\\[\]]+)+\.zip$/i

Matches:

  • https://regexpattern.com/file.zip
  • /path/to/file.zip

Non-matches:

  • https://regexpattern.com/file.rar
  • https://regexpattern.com/file.zip/

See Also:

Rate This Regex
Sending
User Review
0 (0 votes)

Expression Flags

Flags Description
i Ignore case sensitive.
g Allows global search.
m Allows multiline search.