Free dot.case Converter

Convert text or phrases into dot.case format for object notation, configuration files, and namespaced identifiers.

You might also like

View All 136 Tools

About dot.case Converter

Transform any text into dot.case format - the universal notation for object paths, configuration keys, namespaces, and hierarchical identifiers. Perfect for JavaScript object notation, config files, and API response paths.

dot.case uses lowercase letters with periods separating words, creating hierarchical, readable, and parseable identifiers.

How to Use the dot.case Converter

  1. Type or paste your text into the input box
  2. Optional: Enable “Preserve lines” to convert each line separately (perfect for batch conversion)
  3. Click “Convert to dot.case” button
  4. Copy or download your formatted text

The tool works offline after the first load and converts instantly!

What is dot.case?

dot.case (also known as period case or dotted notation) is a naming convention where:

  • All letters are lowercase
  • Words are separated by periods (.)
  • No spaces, hyphens, underscores, or special characters

Example: user profile settingsuser.profile.settings

Why “dot”? The periods create a natural hierarchy, like a path or namespace, making relationships between concepts clear and organized.

Examples

Basic Conversions

Before: User Profile Settings
After: user.profile.settings

Before: Database Connection Config
After: database.connection.config

Before: API Response Data
After: api.response.data

Before: app_environment_variables
After: app.environment.variables

Before: primaryNavigationMenu
After: primary.navigation.menu

Batch Conversion (Preserve Lines)

Before:

Database Connection Host
Database Connection Port
API Key Public
Cache Redis Timeout

After:

database.connection.host
database.connection.port
api.key.public
cache.redis.timeout

Key Features

Instant Conversion - Click button and text converts immediately
Preserve Lines Option - Convert multiple lines independently
Smart Detection - Converts from camelCase, snake_case, kebab-case
Copy & Download - Export as .txt or copy in one click
100% Private - All processing happens in your browser
Works Offline - Functions without internet after initial load

dot.case vs Other Naming Conventions

ConventionExampleSeparatorCaseCommon Usage
dot.caseuser.profile.dataPeriods (.)lowercaseConfigs, object paths
kebab-caseuser-profile-dataHyphens (-)lowercaseURLs, CSS, HTML
snake_caseuser_profile_dataUnderscores (_)lowercasePython, databases
camelCaseuserProfileDataCapital lettersmixedJavaScript variables
PascalCaseUserProfileDataCapital lettersmixedClasses, components
CONSTANT_CASEUSER_PROFILE_DATAUnderscores (_)UPPERCASEConstants, env variables

Key Identifier: dot.case uses periods and is all lowercase.

Common Use Cases

Configuration Files

Perfect for config keys and settings:

const config = {
  "app.name": "MyApp",
  "app.version": "1.0.0",
  "database.connection.host": "localhost",
  "database.connection.port": 5432,
  "api.endpoint.base": "https://api.example.com",
  "features.auth.enabled": true,
};

Object Property Paths

For nested data access:

// Using lodash
import _ from "lodash";
_.get(user, "profile.settings.notifications.email");
_.set(config, "database.connection.host", "localhost");

Translation Keys (i18n)

Organize localization strings:

{
  "common.buttons.submit": "Submit",
  "common.buttons.cancel": "Cancel",
  "forms.fields.email.label": "Email Address",
  "errors.validation.required": "This field is required"
}

Namespaces

For hierarchical identifiers:

// Event names
events.on("user.login.success", handleLogin);
events.on("order.payment.failed", handlePaymentError);

// Package names
com.company.app;
org.project.module;

Best Practices

Effective Naming

Create logical hierarchies
Good: database.connection.host, api.auth.token.expiry
Bad: host.database.connection (illogical order)

Be descriptive but concise
Good: features.auth.enabled, cache.redis.host
Too verbose: application.features.authentication.is.currently.enabled

Ideal depth: 2-4 levels
Good: category.subcategory.property
Too deep: 7+ levels becomes unwieldy

Use consistent patterns
Group related properties: database.primary.host, database.primary.port

Common Patterns

Configuration:

  • app.name, app.version, app.environment
  • database.host, database.port, database.name
  • api.endpoint.base, api.timeout.default

Translations:

  • common.buttons.submit, common.buttons.cancel
  • forms.fields.email.label, forms.fields.password.label
  • errors.validation.required, errors.validation.email.invalid

Events:

  • user.login.success, user.logout
  • order.created, order.payment.success

Frequently Asked Questions

When should I use dot.case?

Use dot.case for:

  • ✅ Object property paths (user.profile.email)
  • ✅ Configuration file keys (database.connection.host)
  • ✅ Translation/i18n keys (common.buttons.submit)
  • ✅ Namespaces and hierarchical identifiers
  • ✅ Event and message names

How do I access dot.case properties in JavaScript?

Three main approaches:

const config = {
  "app.name": "MyApp",
  "database.host": "localhost",
};

// 1. Bracket notation (native)
console.log(config["app.name"]);

// 2. Lodash get (safest)
import _ from "lodash";
_.get(config, "app.name");

// 3. Custom helper
function getConfig(path) {
  return config[path];
}

Note: You cannot use dot notation (config.app.name) because JavaScript interprets the dots as property access.

Is dot.case good for URLs?

No! Use kebab-case for URLs:

  • ❌ URLs: /user.profile.settings (confusing, looks like file extensions)
  • ✅ URLs: /user-profile-settings (clean, SEO-friendly)

Does dot.case work with JSON?

Yes! JSON supports dot.case as property keys:

{
  "app.name": "MyApp",
  "database.host": "localhost"
}

However, nested objects are often clearer for complex data:

{
  "app": { "name": "MyApp" },
  "database": { "host": "localhost" }
}

How deep should my dot.case hierarchy go?

Guidelines:

  • Ideal: 2-4 levels - category.subcategory.property
  • Maximum: 5-6 levels - app.module.feature.setting.option
  • Avoid: 7+ levels - becomes hard to manage

Can I use dot.case for environment variables?

Problematic: Most systems don’t support dots in env var names.

Workaround: Use snake_case or double underscores in env vars, then map to dot.case in code:

// .env
DATABASE__CONNECTION__HOST = localhost;

// config.js
const config = {
  "database.connection.host": process.env.DATABASE__CONNECTION__HOST,
};

Is dot.case case-sensitive?

Yes! Always use lowercase for consistency:

config["app.name"]; // lowercase (standard)
config["App.Name"]; // mixed case (confusing)
config["APP.NAME"]; // uppercase (avoid)

Can I use dot.case for CSS custom properties?

No! CSS custom properties use kebab-case:

/* ❌ Invalid - dots not allowed */
--color.primary: #007bff;

/* ✅ Valid - use kebab-case */
--color-primary: #007bff;

When should I use dot.case vs snake_case?

Use dot.case for:

  • Object property paths and hierarchies
  • Config keys emphasizing structure
  • Translation keys
  • Namespaces

Use snake_case for:

  • Database column names
  • Python variables
  • Environment variables (system limitations)

Key difference: dot.case emphasizes hierarchy, snake_case emphasizes separation.

Is my text data private?

Absolutely! All conversion happens in your browser using JavaScript. We never send your text to servers, store it, or transmit it anywhere. Your data remains completely private.

From the same team