# Pretty links not working

**URL:** <https://help.nextcloud.com/t/pretty-links-not-working/23058>\
**Category:** ℹ️ Support\
**Created:** [November 2, 2017, 10:22am UTC](https://help.nextcloud.com/t/pretty-links-not-working/23058 "2017-11-02T10:22:13Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![BrechtLap](https://help.nextcloud.com/letter_avatar/brechtlap/32/5_5575768a8748004e209b776fc1b2916d.png) [@BrechtLap](https://help.nextcloud.com/u/BrechtLap)\
**Post date:** [November 2, 2017, 10:22am UTC](https://help.nextcloud.com/t/pretty-links-not-working/23058/1 "2017-11-02T10:22:15Z")

</div>

Hey.

I followed this tutorial:

> **[Installing Nextcloud on Ubuntu 16.04 LTS with Redis, APCu, SSL & Apache](https://bayton.org/docs/nextcloud/installing-nextcloud-on-ubuntu-16-04-lts-with-redis-apcu-ssl-apache/)**
>
> A few weeks ago the self-hosted community witnessed the public launch of Nextcloud, an (as of writing) already vastly-improved fork of ownCloud. Having almost finished migrating data on my home ser…

My Nextcloud is up and running, but I can’t for the life of me enable the use of pretty links.

I started digging into the server manual and found this:  
[https://docs.nextcloud.com/server/12/admin\_manual/installation/source\_installation.html#pretty-urls-label](https://docs.nextcloud.com/server/12/admin_manual/installation/source_installation.html#pretty-urls-label)

mod\_env and mod\_rewrite are enabled.  
I added the line htaccess.RewriteBase

I executed the occ command.

I restarted my apache2 service and rebooted my machine too, it’s still not working.

I’m at a loss here, what is not working correctly?

I have the following error log:  
[Thu Nov 02 10:45:25.663433 2017] [mpm\_prefork:notice] [pid 1797] AH00169: caught SIGTERM, shutting down  
[Thu Nov 02 10:45:26.673956 2017] [ssl:warn] [pid 2430] AH01909: nextcloudbrecht.duckdns.org:443:0 server certificate does NOT include an ID which matches the server name  
[Thu Nov 02 10:45:26.709876 2017] [ssl:warn] [pid 2431] AH01909: nextcloudbrecht.duckdns.org:443:0 server certificate does NOT include an ID which matches the server name  
[Thu Nov 02 10:45:26.713421 2017] [mpm\_prefork:notice] [pid 2431] AH00163: Apache/2.4.18 (Ubuntu) OpenSSL/1.0.2g configured – resuming normal operations  
[Thu Nov 02 10:45:26.713444 2017] [core:notice] [pid 2431] AH00094: Command line: ‘/usr/sbin/apache2’

Greetings

---

<div class="post-metadata">

**Author:** ![MichaIng](https://help.nextcloud.com/user_avatar/help.nextcloud.com/michaing/32/2125_2.png) [@MichaIng](https://help.nextcloud.com/u/MichaIng)\
**Post date:** [November 2, 2017, 11:18am UTC](https://help.nextcloud.com/t/pretty-links-not-working/23058/2 "2017-11-02T11:18:08Z")

</div>

The `occ maintenance:update:htaccess` should have added some rewrite block to the end of your `/path/to/nextcloud/.htaccess` file, could you verify that/provide the last block of that file?

Recheck if your webserver really uses the `.htaccess` file. Provide the related webserver config file (`AllowOverride All` should be thwre), or just do a real check by adding some wanted syntax error to `.htaccess` and see if access to Nextcloud web ui breaks as expected.

Finally even if everything works as expected, your browser might have too much left in its cache. Try another browser or clear browser cache, just in case. Hmm this should properly have been done first 😄.

---

<div class="post-metadata">

**Author:** ![riegerCLOUD](https://help.nextcloud.com/user_avatar/help.nextcloud.com/riegercloud/32/53593_2.png) [@riegerCLOUD](https://help.nextcloud.com/u/riegerCLOUD)\
**Post date:** [November 2, 2017, 11:44am UTC](https://help.nextcloud.com/t/pretty-links-not-working/23058/3 "2017-11-02T11:44:36Z")

</div>

Please try to add this statement to Nextclouds config.php:

> ‘htaccess.IgnoreFrontController’ =\> true,

I described the procedure [here](https://www.c-rieger.de/apache2-using-mpm_event/)

Restart your browser and you should be fine?!  
Cheers, Carsten

---

<div class="post-metadata">

**Author:** ![BrechtLap](https://help.nextcloud.com/letter_avatar/brechtlap/32/5_5575768a8748004e209b776fc1b2916d.png) [@BrechtLap](https://help.nextcloud.com/u/BrechtLap)\
**Post date:** [November 2, 2017, 12:06pm UTC](https://help.nextcloud.com/t/pretty-links-not-working/23058/4 "2017-11-02T12:06:16Z")

</div>

I fixed it! The fault was in my config.php.

‘htaccess.RewriteBase’ =\> ‘/nextcloud’, was into the array() instead of out of that. So I put ‘htaccess.RewriteBase’ =\> ‘/nextcloud’, outside of the array, issued the maintance:update command, restarted apache2 and now it works!

Thanks for your help!

---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [December 2, 2024, 2:52pm UTC](https://help.nextcloud.com/t/pretty-links-not-working/23058/5 "2024-12-02T14:52:58Z")

</div>



---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [December 4, 2024, 2:06pm UTC](https://help.nextcloud.com/t/pretty-links-not-working/23058/6 "2024-12-04T14:06:01Z")

</div>


