Documentation
Feedback
Guides
Storefront Development

Storefront Development

Enabling My Account for B2B stores

Learn how to enable the experimental My Account feature in your B2B FastStore store.

This is an experimental feature available only for B2B stores. B2C stores should continue using the standard integration guide.
In this guide, you'll learn how to enable the experimental My Account feature in your B2B FastStore store. By the end of this guide, you will have configured your store to use the new My Account experience, allowing your customers to manage their accounts directly within FastStore.
Unlike the standard integration of My Account, which was based on the VTEX IO platform and accessed through a subdomain configured in the discovery.config.js file, this version uses a FastStore-based setup that allows you to enable and manage My Account directly within FastStore. This feature is available only for B2B stores. B2C stores should continue using the standard version by following the Integrating VTEX Order Placed and My Account guide. While this article discusses the Order Placed page, the experimental feature covered in this guide is solely related to the My Account section.

Before you begin

Make sure you're using the latest version of @faststore/cli. If the version is not updated, see Updating the @faststore/cli package version.

Instructions

To enable the experimental My Account feature in your project, follow the steps below:
  1. Open the discovery.config.js file.
  2. In the experimental object, set the enableFaststoreMyAccount value to true:
    discovery.config.js

    _10
    experimental: {
    _10
    enableFaststoreMyAccount: true,
    _10
    }

  3. Commit and push your changes to the main branch to deploy the changes to production.
With the enableFaststoreMyAccount flag set to true, users accessing the /pvt/account path will be redirected to the /pvt/account/profile page.
The enableFaststoreMyAccount flag overrides the URL specified in the accountUrl property of the discovery.config.js file. If the flag isn't set or is set to false, users will be redirected to the URL configured in the accountUrl property.

Next steps

Now that the experimental My Account feature is enabled in your project, you can:
  • Extend My Account: Create custom pages or add new sections to the default pages by following the guide Extending My Account.
  • Configure Shopper entity access: Enable access to Shopper information (such as the "Ordered by" card) by following the guide Configuring Shopper entity access.
Contributors
1
Photo of the contributor
Was this helpful?
Yes
No
Suggest Edits (GitHub)
Contributors
1
Photo of the contributor
Was this helpful?
Suggest edits (GitHub)
On this page