In short.
This Claude Code guide teaches CLI and SDK maintainers to recommend their plugins during command execution, but marketplace eligibility and session restrictions limit when users see a prompt. A command emits a single-line tag through stderr; Claude Code removes it from Bash or PowerShell output before the model sees it and can present an installation dialog. The guide provides concrete examples and explains environment detection, user choices and suppression rules. Costs, licensing and actual runtime results are not established by the page.
Researched and written by an AI model and checked by a second AI model. How it works
Covers the complete documentation page at [https://code.claude.com/docs/en/plugins/cli-hints.md], including its version note, examples, tag format, prompt restrictions and user choices. Linked documentation about official marketplace names, publishing, environment variables, data usage, installation and commands is excluded. No examples were executed, and runtime behavior, marketplace availability and installation outcomes were not tested.
The overview
Resource identity
Recommend your plugin from your CLI is a Claude Code documentation guide at [https://code.claude.com/docs/en/plugins/cli-hints.md]. It describes adding plugin recommendations to an existing CLI or SDK. The page supplies implementation guidance and examples; it does not supply an installable plugin.
Practical assessment
The guide is useful for maintainers whose plugins already meet official marketplace requirements. It provides the emission format and the conditions governing prompt display, making it possible to plan an implementation from the page.
Its usefulness depends on the intended audience's environment. A correctly emitted tag does not guarantee a prompt, and the page provides no measurements of installation uptake or implementation reliability.
Who it serves
The primary audience is CLI and SDK maintainers with a plugin listed in an eligible official marketplace. Beginners get short examples in four languages; experienced developers get details about subprocess detection, output handling and prompt suppression.
Claude Code users retain the installation decision. Accepting the dialog installs the plugin at user scope, and users can decline or disable future plugin installation hints.
What the feature does
An eligible command can trigger a plugin recommendation dialog showing the plugin name, marketplace and description. The dialog identifies the first word of the shell command Claude Code ran, helping the user recognize which command made the recommendation.
Installation requires the user's acceptance. Choosing the permanent opt-out disables future hint prompts for that user, while leaving the dialog unanswered for 30 seconds counts as declining.
Using it
Eligibility and prerequisites
The plugin must be discoverable in Claude Code's local copy of an official marketplace, must not already be installed and must not be blocked by policy. The examples use claude-plugins-official. The page explicitly excludes claude-community; the complete list of official marketplace names is on a linked page whose contents are not included here.
Prompt display requires a local, attended, interactive terminal session with analytics enabled. The user must not have disabled installation hints, and the session and lifetime frequency limits must allow another prompt.
How the hint works
The CLI writes a tag to stderr, the output stream commonly used for diagnostics. The tag must occupy its own line. Claude Code removes the line from Bash and PowerShell tool output before passing that output to the model.
All three attributes are required: v must be 1, type must be plugin, and value identifies the plugin as name@marketplace. Values can be double-quoted or unquoted, but unquoted values cannot contain whitespace. A tag embedded within another line is ignored. The documentation says a hint line is removed even when its v or type value is unrecognized.
Implementation approach
Add conditional emission to the CLI or SDK and substitute the actual plugin identifier. The guide provides Node.js, Python, Go and shell examples, each checking CLAUDECODE before writing the tag to stderr.
Choose the environment check deliberately. CLAUDECODE is documented across Claude Code versions, but IDE extensions also set it in integrated terminals, so it can match commands a person starts manually there. CLAUDE_CODE_CHILD_SESSION identifies subprocesses Claude Code itself starts and requires v2.1.172 or later.
Illustrative use
The documentation uses this placeholder tag: <claude-code-hint v="1" type="plugin" value="example-cli@claude-plugins-official" />. A CLI emits it as a separate stderr line when its environment check passes.
If every prompt condition also passes, the illustrated dialog offers to install example-cli. Accepting installs it at user scope. The name example-cli is an example identifier; the page does not establish a real plugin's availability or demonstrate an observed installation.
Assessment & evidence
Prompt restrictions
No prompt appears in claude -p runs, subagent runs or hook command output; the tag is stripped in those contexts. Cloud or remote workspaces and unattended sessions do not prompt. The page specifically includes sessions started with --cloud, sessions serving Remote Control and agent-team teammates among excluded cases.
Disabling analytics suppresses prompts. The page names DISABLE_TELEMETRY, DO_NOT_TRACK and CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC, and gives Amazon Bedrock as an example where a provider-related automatic telemetry opt-out applies.
The limits are one prompt per session, one prompt ever per plugin regardless of the user's answer, and no further prompts after 100 plugins have been prompted for on that machine. A CLI may emit the tag on every invocation, but repeated emission does not override these limits.
Implications for adoption
The documented mechanism gives users an installation choice without requiring the model to interpret the hint. Because prompt display depends on several independent gates, emitter correctness and successful recommendation delivery are separate questions.
These restrictions imply limited reach for audiences using remote automation, analytics opt-outs or community marketplaces. The page provides no data quantifying that reach or showing whether recommendations increase plugin adoption.
Other installation paths
For installation outside a session, the page points to a plugin installation command in the commands reference [https://code.claude.com/docs/en/plugins/cli-reference.md#plugin-install]. It also links to publishing and distribution guidance [https://code.claude.com/docs/en/plugins/publish.md].
Those linked pages are outside the available evidence. Their command syntax, distribution options and comparative requirements are not assessed here.
Evidence and verification limits
The evidence is the complete documentation page at [https://code.claude.com/docs/en/plugins/cli-hints.md], including language examples, protocol rules, eligibility restrictions and an illustrative dialog.
No code or commands were executed. Tag interception, prompt display, suppression behavior and installation outcomes remain unverified in actual sessions. The examples describe intended behavior and do not establish test results.
Access & freshness
Costs
The page gives no prices for the hint feature, Claude Code access, marketplace publication or recommended plugins. Access charges, plugin fees and operating costs are unknown from this evidence.
Licensing and reuse
The page includes no explicit license for its text or code examples and no license terms for recommended plugins. Redistribution permissions, sample-code reuse terms and plugin-specific usage rights are not established by this page. Official marketplace eligibility does not establish those rights.
Date and version context
The documentation was captured on 15 November 2026 at 08:00 UTC. Its publication and last-update dates are not provided, and later changes are unknown.
The stated v2.1.172 threshold applies specifically to CLAUDE_CODE_CHILD_SESSION. It does not establish the earliest Claude Code release supporting installation hints.
Next steps for maintainers
Confirm the plugin's official marketplace eligibility, local discoverability and policy allowance. Choose an environment check suited to the supported Claude Code versions, then emit the required tag on its own stderr line.
The guide suggests comparing CLAUDECODE=1 example-cli with an invocation without the variable to check conditional emission. That checks the emitter only. Observing the dialog and installation would require a separate local interactive session meeting every eligibility and frequency condition. Plugin pricing and license terms also need separate evidence.
