How to Deploy Third-Party Web Pages to Subdirectories: A Complete Guide (Including SEO Optimization)

How to Deploy Third-Party Web Pages to Subdirectories: A Complete Guide (Including SEO Optimization)
CapGo AI founder YG's speech on AI SEO at the Ahrefs Summit

In simple terms: After generating a large number of web pages, to maximize SEO traffic, the brand (hello.com) needs to first place the web pages on the subdomain abc.hello.com, then use a reverse proxy to place the web pages on hello.com/abc

In current website content distribution and SEO strategy, deploying third-party generated webpages (such as Webflow, Framer, CapGo.ai, WordPress, etc.) to a subdirectory of the main site (rather than a subdomain) is a more advantageous approach. This article will systematically explain this process, from SEO-related pros and cons analysis to DNS configuration, CNAME and TXT Record settings, reverse proxy operations, and alternative solutions, helping you seamlessly integrate the process.

Table of Contents

  1. The Impact of Subdomains and Subdirectories on SEO
  2. Overview of Steps to Integrate Webflow or Capco Websites into Subdirectories
  3. DNS Settings: Introduction and Configuration of CNAME and TXT Records
  4. Implementing Subdirectory Deployment Using a Reverse Proxy
  5. Alternative Solution: Exporting HTML Files for Manual Upload

The Impact of Subdomains and Subdirectories on SEO

From a structural perspective:Subdomains (e.g., blog.example.com) are treated by search engines as “independent websites.”Subdirectories (e.g., example.com/blog) are treated as part of the main site.

Which is better for SEO?

Although Google has stated that there is little difference between subdomains and subdirectories in terms of ranking, extensive SEO practice has shown that using subdirectories makes it easier to inherit the main site's authority and trustworthiness, resulting in better ranking performance.✅ Recommended: Deploy pages generated by Webflow or CapGo.ai to a subdirectory of the main site (e.g., example.com/landing/).

Steps to integrate the website into a subdirectory

  1. Prepare the page: Complete the webpage design and publish it in Webflow or CapGo.ai.
  2. Obtain the page access URL: Record the URL after publishing in Webflow or CapGo.ai.
  3. Configure DNS: Connect Webflow or CapGo's domain name service to your domain name.
  4. Set up a reverse proxy: Point the subdirectory to Webflow or CapGo.ai content.
  5. (Optional) Download the HTML file and upload it to the main site server as a static resource deployment.

DNS settings: CNAME and TXT records

When connecting a third-party platform to your domain name, you first need to modify the DNS records. You can do this in your domain management platform (such as Cloudflare, Alibaba Cloud, Namecheap, etc.).

What is a CNAME Record?

A CNAME (Canonical Name) record is used to map a subdomain to another domain.Example: Point webflow.example.com to proxy-ssl.webflow.com.

What is a TXT Record?

A TXT record is used to store text information, typically for identity verification purposes, such as:Domain ownership verification (e.g., Google Search Console)SSL certificate application verificationEmail service SPF/DKIM verification🛠️ Practical Tip: Webflow typically requires you to add a CNAME and a TXT record to verify the domain and enable SSL.

Implementing Subdirectory Deployment via Reverse Proxy

What is a Reverse Proxy?

A reverse proxy refers to: the main server acting as an intermediary for client requests, forwarding the requests to the backend Webflow/CapGo website, and then returning the response to the user.

Example:

When a user accesses example.com/landing/:

  1. The request is sent to your main server (e.g., Nginx or Apache).
  2. The main server forwards the request to webflow.example.com via the reverse proxy.
  3. The returned webpage content is then “wrapped” under the /landing/ path and returned to the user.

Nginx configuration example:

location /landing/ {proxy_pass https://webflow.example.com/;proxy_set_header Host webflow.example.com;proxy_set_header X-Real-IP $remote_addr;}⚠️ Note on path handling: Ensure that static resources in subdirectories load properly (JS and CSS paths must be mapped consistently).

Alternative solution: Upload HTML files to the main site

If you do not want to use a reverse proxy, you can use another method:

  1. Export static web pages from Webflow/CapGo.ai:

This is typically a compressed package containing HTML, CSS, JS, images, and other files.

  1. Upload to the /landing/ directory on your main site server:

Use FTP, SCP, or the website's backend management system for upload.

Advantages:

Faster loading and more stable page performance.No need to configure a reverse proxy or worry about cross-domain issues.

Disadvantages:

Inconvenient for content updates; each modification requires re-exporting and re-uploading.Not suitable for dynamic content.

Summary and Best Practices

SolutionAdvantagesDisadvantagesRecommended Scenarios
Subdirectory + Reverse ProxyGood SEO, automatic content updatesComplex configurationRecommended as the first choice
Subdomain DeploymentSimple configuration, supports native platform integrationIndependent SEO weightingOptional backup solution
Static HTML UploadStable and fast, pure frontend deploymentNot suitable for frequent updatesUse when there are few pages

🔚 Final reminder: If you prioritize optimal SEO performance and brand consistency, we recommend prioritizing the subdirectory + reverse proxy deployment method.

Read more

新手必读|5 分钟完成 Google Search Console(GSC)注册指南

新手必读|5 分钟完成 Google Search Console(GSC)注册指南

结论先行:为什么你一定要注册 GSC? 如果你希望你的网站: * 能被 Google 正确收录 * 能被潜在客户在搜索中找到 * 能持续获得自然流量增长 那么 Google Search Console(简称 GSC)是第一步,也是必做的一步。 GSC 是 Google 官方提供的免费工具,用来帮助网站所有者了解并优化网站在 Google 搜索中的表现。你可以把它理解为: 这是 Google 给网站主的“官方后台”。 通过 GSC,你可以清楚地知道: * Google 有没有看到、抓取和收录你的网站 * 用户是通过哪些关键词进入你的网站 * 网站是否存在技术或 SEO 问题 👉 无论你是否懂 SEO、是否是技术人员,只要你有网站,就应该注册 GSC。 一、什么是 Google Search Console?

By CapGo AI - by YG
新手也能看懂|CapGo 网页是如何上线到你官网的?

新手也能看懂|CapGo 网页是如何上线到你官网的?

先说结论 如果你用 CapGo 生成了很多 SEO / GEO 网页,下一步最重要的事只有一件: 👉 把这些网页“放到你的官网里”,而且是用对搜索引擎最友好的方式。 CapGo 帮你把网页上线到官网,一共有三种方式: 1. HTML 文件上传:把网页文件直接放进你的服务器 2. 子域名:网页显示在 xxx.你的域名 下 3. 反向代理:网页显示在 你的域名/目录 下 核心结论很简单: * Google 只看 HTML 内容本身,不关心你用什么技术 * 但 Google 非常在意:这些内容算不算你主站的一部分 * 对 90% 的中大型公司来说,反向代理 = 上线最快 + SEO 效果最好 + 最省人力 下面我们用不讲技术术语的方式,一步一步讲清楚。

By CapGo AI - by YG