Your IP : 216.73.217.64
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Enable index.php-less URLs — ownCloud 10.0.1 Server Administration Manual 10.0.1 documentation</title>
<link rel="stylesheet" href="../_static/" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../_static/main.min.css" type="text/css" />
<link rel="stylesheet" href="../_static/styles.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '10.0.1',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<script type="text/javascript" src="../_static/js/jquery-1.11.0.min.js"></script>
<script type="text/javascript" src="../_static/js/jquery-fix.js"></script>
<script type="text/javascript" src="../_static/bootstrap-3.1.0/js/bootstrap.min.js"></script>
<script type="text/javascript" src="../_static/bootstrap-sphinx.js"></script>
<link rel="top" title="ownCloud 10.0.1 Server Administration Manual 10.0.1 documentation" href="../contents.html" />
<link rel="up" title="Server Configuration" href="index.html" />
<link rel="next" title="User Management" href="../configuration_user/index.html" />
<link rel="prev" title="ownCloud Server Tuning" href="oc_server_tuning.html" />
<meta charset='utf-8'>
<meta http-equiv='X-UA-Compatible' content='IE=edge,chrome=1'>
<meta name='viewport' content='width=device-width, initial-scale=1.0, maximum-scale=1'>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="theme-color" content="#1d2d44">
</head>
<body role="document">
<div class="wrap container not-front">
<div class="content row">
<main class="main">
<div class="row page-content-header">
<div class="col-md-5 col-md-offset-7">
<form class="headersearch" style="margin-bottom:-3px;" action="../search.html" method="get">
<input type="text" value="" name="q" id="q" class="form-control" />
<button class="btn btn-default" type="submit" id="searchsubmit">Search</button>
</form>
</div>
</div>
<div class="row">
<div class="col-md-3">
<div class="sidebar">
<div class="menu-support-container">
<ul id="menu-support" class="menu">
<ul>
<li><a href="../contents.html">Table of Contents</a></li>
</ul>
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="../index.html">Introduction</a></li>
<li class="toctree-l1"><a class="reference internal" href="../release_notes.html">Release Notes</a></li>
<li class="toctree-l1"><a class="reference internal" href="../whats_new_admin.html">What’s New in ownCloud 10.0.1</a></li>
<li class="toctree-l1"><a class="reference internal" href="../installation/index.html">Installation</a></li>
<li class="toctree-l1"><a class="reference internal" href="../configuration_database/index.html">Database Configuration</a></li>
<li class="toctree-l1"><a class="reference internal" href="../configuration_files/index.html">File Sharing and Management</a></li>
<li class="toctree-l1"><a class="reference internal" href="../maintenance/index.html">Maintenance</a></li>
<li class="toctree-l1"><a class="reference internal" href="../configuration_mimetypes/index.html">Mimetypes Management</a></li>
<li class="toctree-l1 current"><a class="reference internal" href="index.html">Server Configuration</a><ul class="current">
<li class="toctree-l2"><a class="reference internal" href="security_setup_warnings.html">Warnings on Admin Page</a></li>
<li class="toctree-l2"><a class="reference internal" href="import_ssl_cert.html">Importing System-wide and Personal SSL Certificates</a></li>
<li class="toctree-l2"><a class="reference internal" href="occ_command.html">Using the occ Command</a></li>
<li class="toctree-l2"><a class="reference internal" href="activity_configuration.html">Configuring the Activity App</a></li>
<li class="toctree-l2"><a class="reference internal" href="antivirus_configuration.html">Virus Scanner Support</a></li>
<li class="toctree-l2"><a class="reference internal" href="caching_configuration.html">Configuring Memory Caching</a></li>
<li class="toctree-l2"><a class="reference internal" href="background_jobs_configuration.html">Background Jobs</a></li>
<li class="toctree-l2"><a class="reference internal" href="config_sample_php_parameters.html">Config.php Parameters</a></li>
<li class="toctree-l2"><a class="reference internal" href="email_configuration.html">Email Configuration</a></li>
<li class="toctree-l2"><a class="reference internal" href="excluded_blacklisted_files.html">Excluding Directories and Blacklisting Files</a></li>
<li class="toctree-l2"><a class="reference internal" href="external_sites.html">Linking External Sites</a></li>
<li class="toctree-l2"><a class="reference internal" href="custom_client_repos.html">Custom Client Download Repositories</a></li>
<li class="toctree-l2"><a class="reference internal" href="knowledgebase_configuration.html">Knowledge Base Configuration</a></li>
<li class="toctree-l2"><a class="reference internal" href="language_configuration.html">Language Configuration</a></li>
<li class="toctree-l2"><a class="reference internal" href="logging_configuration.html">Logging Configuration</a></li>
<li class="toctree-l2"><a class="reference internal" href="harden_server.html">Hardening and Security Guidance</a></li>
<li class="toctree-l2"><a class="reference internal" href="reverse_proxy_configuration.html">Reverse Proxy Configuration</a></li>
<li class="toctree-l2"><a class="reference internal" href="thirdparty_php_configuration.html">Using Third Party PHP Components</a></li>
<li class="toctree-l2"><a class="reference internal" href="js_css_asset_management_configuration.html">JavaScript and CSS Asset Management</a></li>
<li class="toctree-l2"><a class="reference internal" href="automatic_configuration.html">Automatic Configuration Setup</a></li>
<li class="toctree-l2"><a class="reference internal" href="oc_server_tuning.html">ownCloud Server Tuning</a></li>
<li class="toctree-l2 current"><a class="current reference internal" href="">Enable index.php-less URLs</a><ul>
<li class="toctree-l3"><a class="reference internal" href="#prerequisites">Prerequisites</a></li>
<li class="toctree-l3"><a class="reference internal" href="#configuration-steps">Configuration steps</a></li>
<li class="toctree-l3"><a class="reference internal" href="#troubleshooting">Troubleshooting</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../configuration_user/index.html">User Management</a></li>
<li class="toctree-l1"><a class="reference internal" href="../issues/index.html">Issues and Troubleshooting</a></li>
<li class="toctree-l1"><a class="reference internal" href="../enterprise/index.html">Enterprise Features</a></li>
</ul>
</ul>
</div>
</div>
</div>
<div class="col-md-9">
<div class="page-content">
<ul class="prevnext-title list-unstyled list-inline">
<li class="prev">
<a href="oc_server_tuning.html" title="Previous Chapter: ownCloud Server Tuning"><span class="glyphicon glyphicon-chevron-left visible-sm"></span><span class="hidden-sm">« ownCloud Serv...</span>
</a>
</li>
<li class="next">
<a href="../configuration_user/index.html" title="Next Chapter: User Management"><span class="glyphicon glyphicon-chevron-right visible-sm"></span><span class="hidden-sm">User Management »</span>
</a>
</li>
</ul>
<div class="section" id="enable-index-php-less-urls">
<h1>Enable index.php-less URLs<a class="headerlink" href="#enable-index-php-less-urls" title="Permalink to this headline">¶</a></h1>
<p>Since ownCloud 9.0.3 you need to explicitly configure and enable index.php-less URLs
(e.g. <a class="reference external" href="https://example.com/apps/files/">https://example.com/apps/files/</a> instead of <a class="reference external" href="https://example.com/index.php/apps/files/">https://example.com/index.php/apps/files/</a>).
The following documentation provides the needed steps to configure this for the <code class="docutils literal"><span class="pre">Apache</span></code>
Web server. These steps are not necessary when using NGINX as a web server because it is already
enabled in the <a class="reference internal" href="../installation/nginx_examples.html"><em>NGINX Example Configurations</em></a>.</p>
<div class="section" id="prerequisites">
<h2>Prerequisites<a class="headerlink" href="#prerequisites" title="Permalink to this headline">¶</a></h2>
<p>Before being able to use index.php-less URLs you need to enable the <code class="docutils literal"><span class="pre">mod_rewrite</span></code> and
<code class="docutils literal"><span class="pre">mod_env</span></code> Apache modules. Furthermore a configured <code class="docutils literal"><span class="pre">AllowOverride</span> <span class="pre">All</span></code> directive
within the vhost of your Web server is needed. Please have a look at the <code class="docutils literal"><span class="pre">Apache</span></code> manual
for how to enable and configure these.</p>
<p>Furthermore these instructions are only working when using Apache together with the <code class="docutils literal"><span class="pre">mod_php</span></code>
Apache module for PHP. Other modules like <code class="docutils literal"><span class="pre">php-fpm</span></code> or <code class="docutils literal"><span class="pre">mod_fastcgi</span></code> are unsupported.</p>
<p>Finally the user running your Web server (e.g. <code class="docutils literal"><span class="pre">www-data</span></code>) needs to be able to write into the
<code class="docutils literal"><span class="pre">.htaccess</span></code> file shipped within the ownCloud root directory (e.g. <code class="docutils literal"><span class="pre">/var/www/owncloud/.htaccess</span></code>).
If you have applied <a class="reference internal" href="../installation/installation_wizard.html#strong-perms-label"><span>Setting Strong Directory Permissions</span></a> the user might be unable to write into this
file and the needed update will fail. You need to revert this strong permissions temporarily by
following the steps described in <a class="reference internal" href="../maintenance/update.html#set-updating-permissions-label"><span>Setting Permissions for Updating</span></a>.</p>
</div>
<div class="section" id="configuration-steps">
<h2>Configuration steps<a class="headerlink" href="#configuration-steps" title="Permalink to this headline">¶</a></h2>
<p>The first step is to configure the <code class="docutils literal"><span class="pre">overwrite.cli.url</span></code> and <code class="docutils literal"><span class="pre">htaccess.RewriteBase</span></code>
config.php options (See <a class="reference internal" href="config_sample_php_parameters.html"><em>Config.php Parameters</em></a>). If you’re accessing
your ownCloud instance via <code class="docutils literal"><span class="pre">https://example.com/</span></code> the following two options need
to be added / configured:</p>
<div class="highlight-python"><div class="highlight"><pre>'overwrite.cli.url' => 'https://example.com',
'htaccess.RewriteBase' => '/',
</pre></div>
</div>
<p>If the instance is accessed via <code class="docutils literal"><span class="pre">https://example.com/owncloud</span></code> the following
configuration is needed:</p>
<div class="highlight-python"><div class="highlight"><pre>'overwrite.cli.url' => 'https://example.com/owncloud',
'htaccess.RewriteBase' => '/owncloud',
</pre></div>
</div>
<p>As a second step ownCloud needs to enable index.php-less URLs. This is done:</p>
<ul class="simple">
<li>during the next update of your ownCloud instance</li>
<li>by manually running the occ command <code class="docutils literal"><span class="pre">occ</span> <span class="pre">maintenance:update:htaccess</span></code> (See <a class="reference internal" href="occ_command.html"><em>Using the occ Command</em></a>)</li>
</ul>
<p>Afterwards your instance should have index.php-less URLs enabled.</p>
</div>
<div class="section" id="troubleshooting">
<h2>Troubleshooting<a class="headerlink" href="#troubleshooting" title="Permalink to this headline">¶</a></h2>
<p>If accessing your ownCloud installation fails after following these instructions and you see
messages like this in your ownCloud log:</p>
<div class="highlight-python"><div class="highlight"><pre>The requested uri(\\/login) cannot be processed by the script '\\/owncloud\\/index.php'
</pre></div>
</div>
<p>make sure that you have configured the two <code class="docutils literal"><span class="pre">config.php</span></code> options listed above correctly.</p>
</div>
</div>
<ul class="prevnext-title list-unstyled list-inline">
<li class="prev">
<a href="oc_server_tuning.html" title="Previous Chapter: ownCloud Server Tuning"><span class="glyphicon glyphicon-chevron-left visible-sm"></span><span class="hidden-sm">« ownCloud Serv...</span>
</a>
</li>
<li class="next">
<a href="../configuration_user/index.html" title="Next Chapter: User Management"><span class="glyphicon glyphicon-chevron-right visible-sm"></span><span class="hidden-sm">User Management »</span>
</a>
</li>
</ul>
</div>
</div>
</div>
</main>
</div>
</div>
</body>
</html>