Prompt
0 copies · 0 said it worked
Translate source code from one programming language to another
A role prompt that has the model convert code from a source language to a target language, preserving functionality, efficiency, and structure, with explanatory comments added.
People use this for
- convert code between languages
- code translation prompt generator
- port source code to another language
- translate python to javascript code
- convert code to new language with comments
Imported on Nov 29, 2026 from Code Translator: Any Language to Any Language . License observed at the source on Nov 29, 2026: CC0.
Are you the author?Claim this profileRequest removal
Fill in the variables
Prompt
Act as a code translator. You are capable of converting code from any programming language to another. Your task is to take the provided code in {{sourcelanguage}} and translate it into {{targetlanguage}}. Ensure to include comments for clarity and understanding. You will: - Analyze the syntax and semantics of the source code. - Convert the code into the target language while preserving functionality. - Add comments to explain key parts of the translated code. Rules: - Maintain code efficiency and structure. - Ensure no loss of functionality during translation.
No result recorded for this import yet. Tried it? File a report so the next person knows how it went.
Act as a code translator. You are capable of converting code from any programming language to another. Your task is to take the provided code in${sourceLanguage{sourcelanguage}} and translate it into${targetLanguage{targetlanguage}}. Ensure to include comments for clarity and understanding. You will: - Analyze the syntax and semantics of the source code. - Convert the code into the target language while preserving functionality. - Add comments to explain key parts of the translated code. Rules: - Maintain code efficiency and structure. - Ensure no loss of functionality during translation.
Tried it
Structured reports from people who ran this prompt. They roll up into the per-model badges above.
No one has filed a report yet. Try the prompt and be the first.
Related prompts
- Claude api: reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming,…
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER — read BEFORE opening the target file; don't skip because it "looks like a one-liner" — whenever: the prompt names Claude/Anthropic in any fo
Coding · @anthropic
- Structured code translator for porting snippets between languages
Guides a model through a six-step flow (brief, source analysis, challenge map, side-by-side blocks, full idiomatic translated code, summary card) to translate a code snippet between programming languages and versions.
Coding · @sivasaiyadav8143
- Cursor rules enforcing clean, readable, maintainable code practices
A Cursor .mdc rule file that guides the assistant toward clean code: named constants, meaningful names, sparing comments, single-purpose functions, DRY, language style standards, extracted conditionals, continuous refactoring, and version control.
Coding · @patrickjs
- Nginx config security review with fixes and checker script
Agent skill that reviews nginx configs for TLS, header, alias traversal, admin exposure and rate-limit problems, runs a stdlib checker, and returns a minimal route-preserving fixed config with reload and curl test steps.
Coding · @f
- Python docstring coverage and drift checker for code review
A skill-style system prompt that makes the assistant measure Python docstring coverage via AST analysis, flag stale or missing docstrings, and plan a CI-gated documentation fix.
Coding · @f
License: CC0v2 · updated Nov 30, 2026 · first published Nov 29, 2026
Comments
No comments yet. If you tried this prompt, say how it went.