Skip to main content
Development

What is Custom Metadata Type in Salesforce?

Custom Metadata Types are a framework for defining application metadata that can be deployed, packaged, and queried like regular records but stored as metadata rather than data.

Clientell AI, the AI Salesforce admin, documents how Custom Metadata Type is used in your org in a read-only scan, and flags anything risky or unused. See org documentation

Try it in Clientell AI

“Document how Custom Metadata Type is used in my org and list anything that looks risky or unused.”

Clientell reads your org first, drafts every change, and changes nothing until you approve. Platform deployments include rollback. How security works.

Start the 14-day free trial, no card

Term Context

Category

Development

10 terms in this category

Related Terms

4

connected concepts

Glossary

66

total definitions

How does Custom Metadata Type work in Salesforce?

Custom Metadata Types (CMDTs) solve a common problem: storing configuration values that should travel with your metadata during deployments rather than requiring separate data migration. Unlike Custom Settings, CMDT records deploy through change sets, packages, and the Metadata API, making them ideal for mapping tables, feature toggles, integration endpoints, and any configuration that needs to be consistent across environments.

CMDT records can be queried in Apex using standard SOQL without counting against governor limits for the 100-query cap when accessed via the static Trigger or SOQL approach. They support relationships to other metadata types and sObjects, validation rules, and page layouts. Because they are metadata, CMDT records cannot be modified at runtime through DML in production; changes require a metadata deployment or Setup UI edit. This immutability is a feature rather than a limitation: it prevents accidental overwrites and ensures configurations remain auditable. Clientell AI can scaffold custom metadata types and their records to manage org-wide settings cleanly.

Questions people ask

What is a custom metadata type in Salesforce?

A custom object-like type whose records are metadata. You can deploy them between orgs like any other setup.

What is the difference between custom metadata and custom settings?

Custom metadata records move with deployments. Custom setting data does not, so you have to reload it in each org.

Can users edit custom metadata records?

Admins can in Setup. Regular users cannot edit them in the normal record UI.

How do I read custom metadata in Apex?

With SOQL, or with the getAll and getInstance methods on the type.

What should I read next?

Getting Started

Try this on your own org

Start the 14-day free trial, no card. Clientell scans read-only first and changes nothing until you approve.

14-day free trial  ·  No credit card required

SOC 2
HIPAA
GDPR
Salesforce Partner