# 504 gateway timeout when login in

**URL:** <https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414>\
**Category:** Product Support\
**Created:** [July 27, 2020, 9:31pm UTC](https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414 "2020-07-27T21:31:54Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![sylvain59300](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/sylvain59300/32/2978_2.png) [@sylvain59300](https://forum.mautic.org/u/sylvain59300)\
**Post date:** [July 27, 2020, 9:31pm UTC](https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414/1 "2020-07-27T21:31:54Z")

</div>

**Your software**  
My Mautic version is: 3.0.1  
My PHP version is: 7.2

**Your problem**  
My problem is: 504 gateway timeout

These errors are showing in the log: no

Steps I have tried to fix the problem: change php.ini

I have a 504 gateway time out every time I try to access mautic and click the login button. My mutic version is 3.0.1.

Can you help me please?

---

<div class="post-metadata">

**Author:** ![lhpz](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/lhpz/32/2893_2.png) [@lhpz](https://forum.mautic.org/u/lhpz)\
**Post date:** [July 28, 2020, 11:22am UTC](https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414/2 "2020-07-28T11:22:01Z")

</div>

I’ve noticed that login takes around 10 seconds on my Mautic 3.0.1. I guess this is a protection against brute forcing the password.

However, 10 seconds may be too long for the the HTTP server to wait for a response from php-fpm. If this assumption is correct, you have to look into your HTTP server configuration (Nginx?) to fix this. My guess is that `fastcgi_read_timeout` is too low.

---

<div class="post-metadata">

**Author:** ![sylvain59300](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/sylvain59300/32/2978_2.png) [@sylvain59300](https://forum.mautic.org/u/sylvain59300)\
**Post date:** [July 28, 2020, 9:59pm UTC](https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414/3 "2020-07-28T21:59:55Z")

</div>

> [@lhpz](#):
>
> `fastcgi_read_timeout`

Thanks for your help, but how can I change it, I am in cpanel, just I have to add it to php.ini editor mode? wich value must have I to add?

Thanks

---

<div class="post-metadata">

**Author:** ![lhpz](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/lhpz/32/2893_2.png) [@lhpz](https://forum.mautic.org/u/lhpz)\
**Post date:** [July 29, 2020, 7:21am UTC](https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414/4 "2020-07-29T07:21:12Z")

</div>

I’m not familiar with cPanel. The first thing to do is to determine which HTTP server you’re using: Apache ? Nginx ? and then look for the gateway timeout parameter specific to the server you’re using.

---

<div class="post-metadata">

**Author:** ![namratasaun](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/namratasaun/32/2801_2.png) [@namratasaun](https://forum.mautic.org/u/namratasaun)\
**Post date:** [May 14, 2021, 5:22am UTC](https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414/5 "2021-05-14T05:22:30Z")

</div>

Nginx. How can I change it?

---

<div class="post-metadata">

**Author:** ![Diletec](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diletec/32/4432_2.png) [@Diletec](https://forum.mautic.org/u/Diletec)\
**Post date:** [May 14, 2021, 4:14pm UTC](https://forum.mautic.org/t/504-gateway-timeout-when-login-in/15414/6 "2021-05-14T16:14:54Z")

</div>

I have the same problem, but in the settings screen.

The interim solution came from this link: [https://forums.cpanel.net/threads/gateway-time-issue.664781/](https://forums.cpanel.net/threads/gateway-time-issue.664781/)

However, the Mautic settings screen is taking almost 7 minutes to load, so changing the loading limits is not the best solution, it is only a temporary thing.

I even used some microtimes, but I still haven’t located what is delaying this delay.
