Write your own TradingView indicators, alerts and backtests in Pine Script v6. Script structure, types and series, built-ins and multi-timeframe data, inputs and on-chart visuals, repaint-safe alerts, strategy orders with stops and sizing, reading the Strategy Tester honestly, and two full projects.
Module 1: The Pine editor and your first indicator
Where the editor lives, how a script is laid out, indicator() versus strategy(), and plotting close with a moving average.
Module 2: Language basics
Types and qualifiers, series versus simple, var, if and ternaries, functions, arrays, na handling and the errors everyone hits.
Module 3: Built-ins
The ta.* and math.* namespaces, request.security for higher timeframes without lookahead, bar states, sessions and time.
Module 4: Inputs and visuals
Every input.* type with groups and tooltips, shapes and background colour, labels, lines and an on-chart stats table.
Module 5: Alerts
alertcondition versus alert(), message placeholders and webhook JSON, once per bar close, and repainting explained and avoided.
Module 6: Strategies
strategy(), entries and exits, stops and targets with strategy.exit, pyramiding, commission and slippage, sizing by risk, and what a backtest cannot know.
Module 7: Reading the Strategy Tester
Net profit versus expectancy, drawdown, sample size and overfitting, forward testing, the bar magnifier and Deep Backtesting limits.
Module 8: Projects
Build a VWAP plus opening-range breakout indicator with alerts, a pullback-to-EMA strategy with ATR stops, then publish, protect or package as a library.
Educational content, not financial advice.