cd ../blogs
blog7 min read

Reducing Cloud Storage Costs by 10x

How I migrated 4TB of data from AWS S3 to a Hetzner Storage Box — cutting monthly storage costs from $100 to only $13.

#storage#aws#s3#hetzner#rclone#cost-optimization

The Problem

In a previous post, I set up AWS S3 as a local drive on Windows using rclone and WinFsp. It worked well — but as the data grew to 4 TB, the monthly bill climbed to roughly $100/month. For what was essentially a network file share, that's a lot of money.

S3 pricing is simple on paper ($0.023/GB/month for Standard), but it adds up fast at scale. And since our use case was straightforward — a mounted drive for file storage and retrieval — we didn't need S3's global CDN, versioning, or event-driven integrations. We were paying for features we never used.


The Alternative

After researching dedicated storage providers, I found Hetzner Storage Box — a product specifically designed for bulk file storage.

AWS S3 (4 TB)Hetzner Storage Box (5 TB)
Monthly cost~$100$13
Storage includedPay per GB5 TB flat
ProtocolsHTTP API, rcloneSMB/CIFS, SFTP, WebDAV, rsync, rclone
Access modelAPI-based (needs rclone/WinFsp to mount)Native network drive (SMB)
Egress fees$0.09/GB after free tierIncluded

The key difference: Hetzner Storage Box supports SMB/CIFS natively, which means Windows can mount it as a network drive without any third-party tools. No rclone, no WinFsp, no batch scripts — just a standard Windows "Map Network Drive" dialog.

For our use case, this was a strict upgrade at a fraction of the cost.


Step 1 — Mount the Storage Box as a Network Drive (SMB)

The simplest way to access a Hetzner Storage Box from Windows is via SMB — the same protocol used by every office file server and NAS.

  1. Open File Explorer and click on This PC in the left-hand pane.
  2. Click the three dots (...) in the top menu bar to open the "See more" menu, and select Map network drive.
  3. Choose a Drive letter from the dropdown (e.g., Z:).
  4. In the Folder field, enter the share path using Windows backslash notation:
\\u123456.your-storagebox.de\backup 

Replace u123456 with your actual Storage Box username. In case if that doesn't work then try \\<your-storage-box-url>\\backup.

  1. Check Reconnect at sign-in — this ensures the drive remounts automatically after every reboot.
  2. Check Connect using different credentialsthis is crucial. If you skip this, Windows will try to authenticate with your local PC login, which will fail against Hetzner's server.
  3. Click Finish.
  4. A Windows Security prompt will appear:
    • Username: Your Storage Box user ID (e.g., u123456)
    • Password: Your Storage Box password
    • Check Remember my credentials
  5. Click OK.

The Storage Box mounts instantly and opens in a new File Explorer window. It now appears under "This PC" alongside your local C:\ drive, and you can interact with it exactly like any regular folder — drag and drop, copy, paste, open files directly.


VPN Conflicts and Split Tunneling

If you're connected to a corporate or personal VPN, you might find the connection to the Storage Box is extremely slow or fails entirely. This happens because the VPN routes all traffic through its tunnel, including the SMB connection to Hetzner — adding latency and sometimes blocking the required ports.

The fix is split tunneling (sometimes called "Bypass VPN" or "Whitelisting"). Most VPN clients support this:

  1. Open your VPN client's settings.
  2. Find the Split Tunneling section.
  3. Add u123456.your-storagebox.de (your Storage Box hostname) to the bypass/whitelist.

This tells the VPN to route traffic to that specific hostname directly over your regular internet connection, bypassing the VPN tunnel entirely. Everything else continues to go through the VPN as normal.


Step 2 — Add the Storage Box to rclone (SFTP)

While SMB works great for daily file access on Windows, rclone is still the best tool for bulk data transfers — especially for migrating terabytes of data from one provider to another. rclone handles retries, checksumming, parallel transfers, and can resume interrupted copies.

Start the Configuration

Open Command Prompt or PowerShell and run:

rclone config
  1. Type n (New remote) and press Enter.
  2. Name: Enter a name for this remote (e.g., storage-box) and press Enter.

Choose the Storage Type

rclone will present a list of supported storage backends. We need SFTP:

  1. Type sftp and press Enter.

Enter Server Details

  1. Host: Enter your Storage Box address:
u123456.your-storagebox.de
  1. User: Enter your Storage Box username:
u123456
  1. Port: Enter 23 and press Enter.

⚠️ This is a common gotcha — standard SFTP uses port 22, but Hetzner Storage Boxes specifically use port 23 for SFTP. If you leave it at the default, the connection will fail silently.

  1. Password: Type y (Yes, type in my own password) and enter your Storage Box password when prompted.

Skip Advanced Settings

For all remaining prompts (key files, ciphers, etc.), press Enter to accept the defaults. When rclone shows the summary and asks to confirm, type y to save, then q to quit the config menu.


Step 3 — Migrate Data from S3 to the Storage Box

With both remotes configured in rclone (the existing S3 remote from the previous setup and the new storage-box remote), we can copy everything over in a single command:

rclone copy s3-remote:your-bucket-name storage-box: --transfers 8 --checkers 8 -P

Flag Breakdown

FlagPurpose
s3-remote:your-bucket-nameSource — your existing S3 bucket (replace with your remote name and bucket)
storage-box:Destination — the Hetzner Storage Box root directory, note that storage-box: must be the same name that you'd fill in Step 2's Name field.
--transfers 8Run 8 file transfers in parallel
--checkers 8Run 8 hash-checkers in parallel to verify files
-PShow real-time progress (transfer speed, ETA, files remaining)

Replace s3-remote with whatever you named your S3 remote in rclone, and your-bucket-name with your actual S3 bucket name.

How Long Does It Take?

For our 4 TB of data, the transfer took approximately 60 hours. Your time will vary depending on:

  • Network bandwidth between AWS and Hetzner
  • Average file size (many small files are slower than fewer large files)
  • S3 egress throttling at high throughput

💡 If the transfer gets interrupted (network drop, machine restart), just run the same command again. rclone will compare checksums and only copy files that are missing or different — it won't re-transfer everything.


Result

The Storage Box is now live and mounted as a native Windows drive via SMB, with rclone available over SFTP for scripted operations and bulk transfers. Monthly storage cost dropped from ~$100 to ~$13 — a ~10x reduction — while gaining 1 TB of extra capacity and native Windows integration without any third-party filesystem drivers.

MetricBefore (S3)After (Hetzner)
Monthly cost~$100~$13
Total capacityPay-per-GB5 TB flat
Windows integrationrclone + WinFsp + startup scriptsNative SMB network drive
Migration time~60 hours (one-time)