Nextcloud
Your Own Private Cloud Storage and Collaboration Platform
Your Own Private Cloud Storage and Collaboration Platform
Nextcloud is a self-hosted productivity platform that keeps you in control of your data. It provides file sync and share capabilities similar to Dropbox, Google Drive, or OneDrive, but with complete privacy and ownership of your files.
Beyond simple file storage, Nextcloud offers a complete collaboration suite including calendars, contacts, task management, video calls, document editing, and hundreds of apps to extend functionality.
Whether you’re managing personal files, running a small business, or deploying enterprise-wide collaboration tools, Nextcloud gives you the freedom and security of self-hosting without sacrificing features.
Keep all your data on your own server. No third-party access, no data mining, complete privacy and compliance with data protection regulations.
Files, calendars, contacts, email, video calls, document editing, task management, and more – all integrated in one platform.
Access hundreds of apps from the Nextcloud App Store to add features like note-taking, password management, music streaming, and more.
Native desktop clients for Windows, macOS, and Linux. Mobile apps for iOS and Android. Web interface accessible from any browser.
Share files and folders with password protection, expiration dates, and fine-grained permissions. Public links or private shares to users.
LDAP/Active Directory integration, SSO support, detailed audit logs, encryption at rest and in transit, and professional support available.
Follow this step-by-step guide to install Nextcloud using Docker for easy deployment and maintenance.
First, create directories to store Nextcloud data and configuration:
mkdir -p ~/nextcloud/{data,db,config}
cd ~/nextcloud
Create a docker-compose.yml file with the following configuration:
version: '3'
services:
nextcloud-db:
image: mariadb:10.11
container_name: nextcloud-db
restart: unless-stopped
command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW
volumes:
- ./db:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=your_root_password
- MYSQL_PASSWORD=nextcloud_password
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud
networks:
- nextcloud-net
nextcloud-redis:
image: redis:alpine
container_name: nextcloud-redis
restart: unless-stopped
networks:
- nextcloud-net
nextcloud:
image: nextcloud:latest
container_name: nextcloud
restart: unless-stopped
ports:
- "8080:80"
volumes:
- ./data:/var/www/html
- ./config:/var/www/html/config
environment:
- MYSQL_HOST=nextcloud-db
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud
- MYSQL_PASSWORD=nextcloud_password
- REDIS_HOST=nextcloud-redis
depends_on:
- nextcloud-db
- nextcloud-redis
networks:
- nextcloud-net
networks:
nextcloud-net:
driver: bridge
Launch the Nextcloud stack with Docker Compose:
docker-compose up -d
Open your browser and navigate to http://your-server-ip:8080. You’ll see the Nextcloud setup page:
If accessing Nextcloud via a domain name, add it to trusted domains. Edit the config file:
nano ./config/config.php
# Add your domain to the trusted_domains array:
'trusted_domains' =>
array (
0 => 'localhost',
1 => 'your-server-ip',
2 => 'your-domain.com',
),
For production use, set up a reverse proxy with SSL. Using Nginx:
server {
listen 80;
server_name your-domain.com;
return 301 https://$server_name$request_uri;
}
server {
listen 443 ssl http2;
server_name your-domain.com;
ssl_certificate /path/to/cert.pem;
ssl_certificate_key /path/to/key.pem;
client_max_body_size 512M;
fastcgi_buffers 64 4K;
location / {
proxy_pass http://localhost:8080;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
Default Port: 8080 (HTTP)
Security: Always use HTTPS in production and change default passwords!
Performance: Enable Redis caching for better performance with multiple users.
Backups: Regularly backup the ./data and ./db directories!
Configure caching and background jobs for optimal performance:
# Add to config/config.php 'memcache.local' => 'OCMemcacheAPCu', 'memcache.distributed' => 'OCMemcacheRedis', 'memcache.locking' => 'OCMemcacheRedis', 'redis' => [ 'host' => 'nextcloud-redis', 'port' => 6379, ],
Set up cron for background tasks:
docker exec -u www-data nextcloud php cron.php
Install these apps from the Nextcloud App Store (Settings → Apps):
Download native sync clients for automatic file synchronization:
Access your files on the go with mobile apps:
Connect using WebDAV for universal file access:
https://your-domain.com/ remote.php/dav/files/USERNAME/
Compatible with file managers on all operating systems.
Connect external storage sources to Nextcloud:
Work together seamlessly:
Update Nextcloud to the latest version:
# Backup first! docker-compose down docker-compose pull docker-compose up -d
Run maintenance commands:
# File system scan docker exec -u www-data nextcloud php occ files:scan --all # Clear cache docker exec -u www-data nextcloud php occ maintenance:repair
Upload size limit too small:
Increase PHP upload limits by creating .user.ini in the data directory.
Slow performance:
Enable Redis caching and run background jobs via cron instead of AJAX.
Trusted domain error:
Add your domain/IP to the trusted_domains array in config.php.
Database issues:
Run database optimization: docker exec -u www-data nextcloud php occ db:add-missing-indices
Deploy Nextcloud today and enjoy the freedom of self-hosted cloud storage and collaboration.
Nextcloud is open-source software. Visit nextcloud.com for more information and community support.