# HTTPS URL REDIRECT

**URL:** <https://community.f5.com/t/https-url-redirect/6582>\
**Category:** Technical Forums\
**Tags:** big-ip, ltm, application-delivery\
**Created:** [November 18, 2016, 12:27pm UTC](https://community.f5.com/t/https-url-redirect/6582 "2016-11-18T12:27:09Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![real\_ever\_21524](https://avatars.discourse-cdn.com/v4/letter/r/7ba0ec/32.png) [@real\_ever\_21524](https://community.f5.com/u/real_ever_21524)\
**Post date:** [November 18, 2016, 12:27pm UTC](https://community.f5.com/t/https-url-redirect/6582/1 "2016-11-18T12:27:09Z")

</div>

Hello! Can i do redirect to specifield url via HTTPS(SSL Cleint Profile on Virtual Server BIG-IP)? Example:

when HTTP\_REQUEST { if { [HTTP::host] eq "; } { HTTP::redirect [https://abc.com/Specifield](https://abc.com/Specifield) } }

It works only with HTTP, not HTTPS.

---

<div class="post-metadata">

**Author:** ![Niels\_van\_Sluis](https://d1p9zq3aats0t8.cloudfront.net/user_avatar/community.f5.com/niels_van_sluis/32/3759_2.png) [@Niels\_van\_Sluis](https://community.f5.com/u/Niels_van_Sluis)\
**Post date:** [November 18, 2016, 12:48pm UTC](https://community.f5.com/t/https-url-redirect/6582/2 "2016-11-18T12:48:47Z")

</div>

This should work, however the HTTP::host will not contain ‘https://’ only the hostname/ip address and port number if it is a non-standard port.

```tcl
when HTTP_REQUEST {
  if { [HTTP::host] equals"www.xyz.com"} {
    HTTP::redirect "http://www.abc.com/index.html"
  }
}

```

See this link for more information:

- [DevCentral - An F5 Technical Community](https://devcentral.f5.com/wiki/iRules.HTTP__host.ashx)
