What is the purpose of using quote_id_mask Table ?enter image description here


Unknown users cannot obtain private information of your registered customers. It doesn’t include the cart_id_mask value in the quote_id_mask table, it makes difficult for hackers to obtain information of your registered users.


I am not sure but I think this table comes in action when any guest customer add product in their cart. Magento saves masked id with quote id. masked_id is stored in local storage as well.

check below code


<route url="/V1/guest-carts/:cartId" method="GET">
    <service class="Magento\Quote\Api\GuestCartRepositoryInterface" method="get"/>
        <resource ref="anonymous" />


public function get($cartId)
    /** @var $quoteIdMask QuoteIdMask */
    $quoteIdMask = $this->quoteIdMaskFactory->create()->load($cartId, 'masked_id');
    return $this->quoteRepository->get($quoteIdMask->getQuoteId());

magento use masked_id to fetch quote id then fetch quote using quote_id for guest customer.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for?Browse other questions tagged or ask your own question.