diff --git a/Makefile b/Makefile
index 6d24b855b5380fe97b45836a081729fd162d84b4..dd5003ae25deebbf96b961d19f99f5e9552cd08f 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,8 @@
 .PHONY: help
 CURRENT_DIR = $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
 IPNS_KEY = k51qzi5uqu5di18qioib4tu3nn8r51o89eaymk99xkm9lmitbulctduy4a2lzw
-export BASE_URL = https://gateway.ipfs.io/ipns/fdroid.shivering-isles.com
+export WEB_URL = $(shell grep -E '^repo_url' config.py | awk '{gsub(/"/, "", $$3); gsub(/\/fdroid\/repo/, "", $$3);print $$3}')
+export REPO_URL = $(shell echo "$(WEB_URL)" | sed 's/^https/fdroidrepos/')
 export REPO_NAME = $(shell grep -E '^repo_name' config.py | awk '{gsub(/"/, "", $$3);print $$3}')
 export FDROID_FINGERPRINT = $(shell keytool --list -keystore keystore.jks -storepass "$$(grep -E '^keypass' config.py | awk '{gsub(/"/, "", $$3);print $$3}')" | grep 'Certificate fingerprint (SHA-256)' | sed -e 's/Certificate fingerprint (SHA-256): //' -e 's/://g')
 
@@ -23,5 +24,5 @@ html: ./deploy/index.html ./deploy/qr.png ## Prepare all HTML content for the re
 ./deploy/index.html:
 	envsubst <_templates/index.html.template > ./deploy/index.html
 ./deploy/qr.png:
-	qrencode -o deploy/qr.png "$$BASE_URL/fdroid/repo?fingerprint=$$FDROID_FINGERPRINT"
+	qrencode -o deploy/qr.png "$(REPO_URL)/fdroid/repo?fingerprint=$(FDROID_FINGERPRINT)"
 
diff --git a/_templates/index.html.template b/_templates/index.html.template
index df94e9dc3c87c0a3c452269a54493d64f3edede4..5893092e18e909ed2bbc96e8c98b90fdf6f243cf 100644
--- a/_templates/index.html.template
+++ b/_templates/index.html.template
@@ -15,14 +15,14 @@
 <body style="text-align: center; padding: 20px; max-width: 600px; margin: 0 auto;">
     <h1 style="font-size: 1.7rem;">Shivering-Isles F-Droid</h1>
     <p>
-        <a href="$BASE_URL/fdroid/repo?fingerprint=$FDROID_FINGERPRINT">
+        <a href="$REPO_URL/fdroid/repo?fingerprint=$FDROID_FINGERPRINT">
             <img src="./qr.png" alt="" width="300" height="300" />
         </a>
     </p>
     <h3 style="font-size: 1.25rem;">Repository</h3>
     <div style="text-align: left;">
         URL:
-        <pre><code>$BASE_URL/fdroid/repo</code></pre>
+        <pre><code>$WEB_URL/fdroid/repo</code></pre>
         Fingerprint:
         <pre><code>$FDROID_FINGERPRINT</code></pre>
     </div>