JSON ফরম্যাটার

JSON ডেটা ফরম্যাট, যাচাই ও মিনিফাই করুন

JSON ভিউয়ার
শুরুতে বন্ধ থাকে। কিছুই সেভ হয় না, কোথাও পাঠানোও হয় না।

পুরোপুরি আপনার ব্রাউজারেই চলে। আপনি যা লেখেন বা আপলোড করেন, তার কিছুই আমাদের কাছে পাঠানো বা সংরক্ষণ করা হয় না।

ফলাফল শুধু সাধারণ ধারণার জন্য। গুরুত্বপূর্ণ কোনও কিছুর উপর ভরসা করার আগে দয়া করে যাচাই করে নিন। ব্যবহারের শর্তাবলি

অনুবাদ তৈরি না হওয়া পর্যন্ত নিচের গাইডটি ইংরেজিতে আছে।

কীভাবে ব্যবহার করবেন

  1. আপনার JSON "মূল ইনপুট" বক্সে পেস্ট করুন, অথবা .json ফাইল খুলতে ফাইল খুলুন বোতামে ক্লিক করুন। নমুনা বোতামে ক্লিক করলে একটি উদাহরণ চলে আসে।
  2. টাইপ করার সঙ্গে সঙ্গেই এটি যাচাই হতে থাকে। কোথাও ভুল থাকলে আপনি লাইন ও কলাম নম্বর দেখতে পাবেন, সঙ্গে সেই লাইনটিও, যেখানে ভুলের ঠিক নিচে একটি ^ চিহ্ন থাকবে। সহজ ভাষায় কারণটিও লেখা থাকবে, যেমন কোনও কমা বাদ পড়েছে বা বাড়তি আছে।
  3. সুন্দরভাবে ইন্ডেন্ট করে সাজাতে ফরম্যাট করুন বোতামে ক্লিক করুন (বা Ctrl+Enter টিপুন)। "2টি স্পেস", "4টি স্পেস" বা "ট্যাব" বেছে নিন, আর প্রপার্টিগুলি A থেকে Z ক্রমে সাজাতে প্রপার্টি সাজান চালু করুন। মিনিফাই করুন (Ctrl+Shift+Enter) সবকিছু এক লাইনে নিয়ে আসে।
  4. ডেটা ঘুরে দেখতে JSON ভিউয়ার ব্যবহার করুন। "সব খুলুন" ও "সব গুটিয়ে নিন" প্রতিটি স্তর একসঙ্গে খোলে বা বন্ধ করে।
  5. কপি করুন বোতামে ক্লিক করুন, অথবা .json ফাইল সেভ করতে ডাউনলোড করুন বোতামে। "পরের বারের জন্য আমার JSON এই ডিভাইসে মনে রাখুন" তখনই চালু করুন, যদি আপনি চান পরের বারের জন্য এটি এই ব্রাউজারেই রাখা থাকুক।

What is JSON?

JSON (JavaScript Object Notation) is the standard format for sending data between web APIs, and it's everywhere in config files and databases too. People can read it, and every modern programming language supports it out of the box. Nearly every REST API, from payment gateways to social media, sends and receives JSON. This JSON formatter makes it readable, checks it for errors and shows it as a tree you can expand and collapse.

Where it comes in handy

  • API debugging: copy a response from Postman or your browser's DevTools and format it so you can actually read it.
  • Config files: tidy up package.json, appsettings.json or tsconfig.json.
  • Data pipelines: validate JSON before it goes into a database or message queue.
  • Log analysis: many logging systems write minified JSON. Format it to find the problem faster.

JSON syntax rules

  • Keys must be strings in double quotes: "name", not name.
  • A value can be a string, number, boolean, null, array or object.
  • Trailing commas aren't allowed, unlike in JavaScript objects.
  • Comments aren't allowed either. If you need them in config files, use a JSON5 parser.

So {'name': 'Asha',} fails twice, once for the single quotes and once for the trailing comma. The valid version is {"name": "Asha"}.

সাধারণ প্রশ্নোত্তর

The usual ones: missing commas between elements, unclosed brackets or braces, trailing commas (not allowed in JSON), unquoted keys, single-quoted strings, and control characters inside strings. It also tells you if the input is empty or isn't JSON at all.

No. Formatting and validation happen in your browser, using JavaScript's built-in JSON.parse() and JSON.stringify(). Your data never leaves your device, so it's safe to paste sensitive API responses.

JSON5 is a looser superset of JSON. It allows comments (//, /* */), trailing commas, single-quoted strings and unquoted keys. Some config files use it, such as VS Code's settings.json. Standard JSON parsers reject JSON5, so use a dedicated JSON5 parser for those files.