What is the absolute path to my web hosting package?
The absolute path to your pack’s public HTML directory is:
/home/${pack_name}/html/
${pack_name} must be replaced with the name of your web pack. You can view it in your hosting.fr web hosting product settings as follows:
- Select the “Products” item in the menu on the left.
- In the “Products” menu, select the “Web Hosting” sub-item.
- In the “Web Spaces” section, select “Show details” under the desired web space.

- On the right, you will see a block with access data. Click here on “Show advanced settings”.

- In the advanced overview, you will see the specific absolute path to your web hosting package.

What an absolute path means in web hosting
An absolute path is the complete filesystem location of a directory or file on the server. It always starts at the system root (it begins with /) and does not depend on where a script is executed.
In a webhosting environment, absolute paths are commonly used by server-side processes (PHP, cron, CLI tools) that need an exact location for files or directories. On hosting.de webhosting, the publicly accessible website directory is your html directory inside your package path:
- Public document root: /home/${package_name}/html/
Using the absolute path avoids ambiguity and helps prevent “file not found” errors caused by relative paths resolving differently in different execution contexts.
When and why you need the absolute path
You typically need the absolute path in situations where tools or scripts run outside the website’s normal browser context and cannot reliably resolve relative paths.
Common use cases include:
- Cron jobs / scheduled tasks (e.g., running a PHP script every hour)
- PHP includes and requires (especially when scripts execute from different directories)
- CLI/SSH workflows (running scripts manually on the server)
- Application configuration files that require a filesystem path (not a URL)
- Backup and automation tools that reference directories directly
If you are troubleshooting an integration and see errors such as “No such file or directory,” “failed to open stream,” or “include_path,” confirming and using the correct absolute path is often the fastest fix.
Absolute path vs. relative path
Understanding the difference helps you choose the right approach:
Absolute path
- Full location starting from /
- Does not change based on execution directory
- Example: /home/${package_name}/html/includes/config.php
Relative path
- Location relative to the current working directory or script location
- Can break if a script runs from a different directory (common with cron jobs)
- Example: includes/config.php
As a rule: use absolute paths for server-side automation and system-level configuration, and use relative paths mainly for internal website linking and predictable code paths.
How to find your package name (and your specific absolute path) in the control panel
- In the left menu, select Products.
- Under Products, select Webhosting.
- In the Webspaces section, select Show details for the webspace you want.
- On the right, in the access data overview, click Show advanced settings.
- In the advanced overview, you will see the absolute path specific to your webhosting package.
Practical use cases and best practices
Use the absolute path in a way that is stable, maintainable, and secure:
- Prefer configuration-based paths: Store the absolute path in a config variable once, and reference that variable throughout your code.
- Avoid hardcoding file-by-file paths: Point to a base directory (e.g., /home/${package_name}/html/) and build child paths from it.
- Use absolute paths for cron jobs: Cron tasks often run with a different working directory, so relative paths frequently fail.
- Validate changes after migrations: If you move to a different package or environment, confirm the package name and absolute path again.
- Do not confuse filesystem paths with URLs:
- Filesystem path: /home/${package_name}/html/
- URL: https://yourdomain.tld/
These practices reduce path-related errors and make maintenance significantly easier.