Title Case Converter

***

Use our easy Title Case Converter Tool to elevate your writing! Ideal for students, professionals, and content creators.

Loading...
Loading...
Settings

The Title Case Converter Online Tool is a handy utility that capitalizes your text according to the conventions of title casing. It is particularly useful for formatting headings, titles, or any text where you need each significant word to start with a capital letter, while keeping minor words in lowercase unless they start or end a sentence.

πŸ“˜ Introduction

Title casing is a common requirement in writing and publishing where the first letter of major words in a title or heading is capitalized. This tool automates the process, taking into account common minor words (like prepositions and conjunctions) that do not usually start with a capital letter unless they are at the beginning or the end of the title.

πŸ§‘β€πŸ« Step-by-step Instructions

  1. Input Your Text: Type or paste the text you want to convert into the Editor.
  2. Customize Minor Words (optional): You can specify any additional minor words that should not be capitalized in the middle of the sentence. If no custom list is provided, the tool uses a default list including words like "and", "the", "in", etc.
  3. Convert the Text: Press the convert button, and the tool will transform your input into Title Case.
  4. Review the Output: The converted text will appear. You can copy or further edit this text as needed.

🚨 Common Issues and Solutions

  • Words Incorrectly Capitalized: Ensure that any custom minor words are correctly added. Minor words are case-sensitive in the customization list.
  • Unexpected Results with Mixed Case Inputs: If the original text includes mixed cases, results might vary. It's best to input text in lowercase to ensure uniformity in processing.

🌟 Additional Tips and Recommendations

  • When preparing titles for formal documents or publications, double-check the title case output to ensure it meets specific style guidelines, as conventions can vary slightly.
  • Use this tool to quickly format text for presentations or publications where consistent and professional titling is necessary.

πŸ“ Conclusion

This Title Case Converter is an efficient and easy-to-use tool for anyone needing to format text for headers, titles, or any other content that requires standardized capitalization. Try it out for your next project or document preparation to ensure your titles stand out correctly and professionally. Don't forget to explore related tools for different casing styles like Kebab Case, Snake Case, and more, available through the related links! πŸŽ―πŸ“

More details

/**
 * πŸͺ„ Qit.tools
 * https://qit.tools
 *
 * Converts a string to Title Case, taking into account rules for minor words.
 * Minor words in the middle of the sentence are not capitalized unless
 * they are at the beginning or the end.
 *
 * @param {string} input - The input string to convert to Title Case.
 * @param {string[]} customMinorWords - An optional array of minor words that should not be capitalized,
 *                                      uses a default list if not provided.
 * @return {string} The string in Title Case.
 */
const titleCase = (input: string, customMinorWords?: string[]): string => {
  const defaultMinorWords = [
    "a",
    "an",
    "the",
    "and",
    "but",
    "or",
    "for",
    "nor",
    "on",
    "at",
    "to",
    "from",
    "by",
    "with",
    "in",
    "of",
  ];
  const minorWords = new Set(customMinorWords ?? defaultMinorWords);
 
  return input
    .split(" ")
    .map((word, index, words) => {
      const lowerWord = word.toLowerCase();
      if (
        index === 0 ||
        index === words.length - 1 ||
        !minorWords.has(lowerWord)
      ) {
        return word.charAt(0).toUpperCase() + lowerWord.slice(1);
      }
      return lowerWord;
    })
    .join(" ");
};
 
export default titleCase;
// Qit.tools
// Install lodash
// npm install lodash
 
import { startCase, camelCase } from "lodash";
 
const sample = "hello World";
 
startCase(camelCase(simple)); // Hello World