ToolSpark

JSON to TypeScript

Convert JSON objects into TypeScript interfaces automatically. Supports nested objects, arrays, optional fields, readonly properties, and multiple naming conventions.

Share:𝕏fin
TS{ }
export interface Address {
  street: string;
  city: string;
  zipCode: string;
  country: string;
}

export interface PostsItem {
  id: number;
  title: string;
  published: boolean;
  tags: string[];
}

export interface Root {
  id: number;
  name: string;
  email: string;
  active: boolean;
  age: number;
  address: Address;
  roles: string[];
  posts: PostsItem[];
}

Frequently Asked Questions

Related Tools