**如何设置在小程序内一键关注公众号?**
**一、首先打开微信公众平台 地址:[https://mp.weixin.qq.com/](https://mp.weixin.qq.com/)打开链接,登录绑定商户后台的小程序账号。**
**[![](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_05.png)](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_05.png)**
**二、登录成功后,进入小程序管理后台-设置>关注公众号>公众号关注组件 > 开关开启。**
[![](http://help.youanmi.com/wp-content/uploads/2019/01/%E5%85%AC%E4%BC%97%E5%8F%B7%E5%85%B3%E6%B3%A8%E7%BB%84%E4%BB%B61.png)](http://help.youanmi.com/wp-content/uploads/2019/01/%E5%85%AC%E4%BC%97%E5%8F%B7%E5%85%B3%E6%B3%A8%E7%BB%84%E4%BB%B61.png)
**提示:**如果你的小程序未关联公众号,会出现以下弹窗。解决方法如下:
[![](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_09-1024x507.png)](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_09.png)
**小程序未关联的公众号 解决方法:**
1、点击设置>开发设置>APPID 复制AppID保存在本地,然后退出小程序账号,如下图。
2、回到登录页面,登录需要关联的公众号后台管理账号。
操作步骤可参考:[https://jingyan.baidu.com/article/db55b609dbd34f4ba30a2f93.html](https://jingyan.baidu.com/article/db55b609dbd34f4ba30a2f93.html)微信小程序如何关联到公众号
3、在公众号后台管理中关联成功后,回到小程序账号管理中,继续开启【公众号关注组件】。
[![](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_11.png)](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_11.png)
**三、选择您要关注的同主体公众号,非同主体的无法绑定。**
[![](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_13.png)](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_13.png)
**四、公众号关注组件 开关按钮为绿色就是开通成功啦。**
[![](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_15.png)](http://help.youanmi.com/wp-content/uploads/2019/01/%E6%95%99%E7%A8%8B%E9%A1%B5_15.png)