OPEN-SOURCE SCRIPT
Updated MK_OSFT - Multi-Timeframe MA Dashboard with Alerts - v1.0

Multi-Timeframe Moving Average Dashboard with Advanced Alerts
A comprehensive multi-timeframe moving average indicator that displays MA levels from 6 different timeframes simultaneously on your chart, complete with intelligent labeling, customizable alerts, and performance-optimized plotting.
*** Key Features ***
Multi-Timeframe Analysis
Intelligent Alert System
Flexible Display Options
Advanced Plotting System
Real-Time Information Table
*** Settings Overview ***
Moving Average Settings
Individual Timeframe Controls
Visual Customization
Smart Features
Perfect For
Performance Optimized
Transform your chart into a comprehensive multi-timeframe analysis dashboard with this professional-grade moving average indicator.
A comprehensive multi-timeframe moving average indicator that displays MA levels from 6 different timeframes simultaneously on your chart, complete with intelligent labeling, customizable alerts, and performance-optimized plotting.
*** Key Features ***
Multi-Timeframe Analysis
- Monitor MA levels from 6 timeframes: 5m, 15m, 1H, 4H, Daily, and Weekly
- Clean visual separation with customizable colors for each timeframe
- Smart label positioning prevents overlapping and ensures readability
Intelligent Alert System
- Individual alert toggles for each timeframe
- Cross-above and cross-below MA alerts with once-per-bar frequency
- Alerts only trigger on confirmed timeframe closes (no false signals)
- Works across all trading pairs on your current chart
Flexible Display Options
- Toggle individual timeframe visibility
- Choose between SMA and EMA calculations
- Adjustable MA length (default: 12 periods)
- Two source options: Current Bar or Last Confirmed Bar
- Customizable line widths, label sizes, and colors
Advanced Plotting System
- Optional plot lines that don't clutter your Style tab
- Performance-optimized line drawing with historical data support
- "Wait till close" behavior for smooth higher timeframe representation
- Clean horizontal segments that update only on timeframe closes
Real-Time Information Table
- Live countdown timers showing time remaining until each timeframe closes
- Visual indicators for current price position relative to each MA
- Cross direction indicators (↑/↓) for quick trend assessment
- Show/Alert status display for easy configuration verification
*** Settings Overview ***
Moving Average Settings
- MA Length: Adjustable period (default: 12)
- MA Type: SMA or EMA
- Source: Current bar vs Last confirmed bar
Individual Timeframe Controls
- Show/Hide toggles for each timeframe
- Individual alert enable/disable
- Optional plot line with custom width
- Color customization per timeframe
Visual Customization
- Label size options (tiny, small, normal, large)
- Label offset positioning
- Minimum gap between labels to prevent overlap
- Drawing order preference (larger timeframes first/last)
Smart Features
- Automatic label collision detection and adjustment
- Real-time countdown timers (only on live bars)
- Debug table with comprehensive timeframe information
- Built-in alert setup instructions
Perfect For
- Swing traders monitoring multiple timeframe confluences
- Day traders seeking higher timeframe bias confirmation
- Anyone wanting clean, organized multi-timeframe MA analysis
- Traders who need reliable alerts without false signals
Performance Optimized
- Efficient line drawing system (no Style tab clutter)
- Smart historical data handling
- Minimal resource usage with intelligent update cycles
- Works smoothly on all timeframes and symbols
Transform your chart into a comprehensive multi-timeframe analysis dashboard with this professional-grade moving average indicator.
Release Notes
Added background color, corresponding to the timeframe color, to the TF column of the Info TableRelease Notes
Update v1.1 - Enhanced Time Display & Reliable Alerts🎨 Enhanced Time Left Background Indication
- Multi-zone gradient progress bar: Time remaining now displays with dynamic background colors that change based on how close each timeframe is to closing
- Visual progression: Green (early) → Yellow (mid) → Orange (late) → Red (about to close) with increasing opacity as the bar progresses
- Better at-a-glance monitoring: Instantly see which timeframes are about to complete without reading the exact time
🚨 Improved Alert System - Queued Alerts
- Prevents missed alerts: Fixes TradingView's alert throttling issue where simultaneous alerts from multiple timeframes would get suppressed
- Queue-based delivery: Alerts are now queued and delivered with 3-second intervals to ensure all alerts reach you
- Local timezone support: Alert timestamps now show in your local time instead of UTC
- Enhanced logging: Better Pine Log visibility to track queued vs sent alerts
🔧 Technical Improvements
- More reliable notifications: No more missed alerts when multiple timeframes cross simultaneously
- Cleaner alert messages: Consistent formatting with local timestamps
- Better debugging: Enhanced logging system to monitor alert queue status
Note: These changes ensure you receive ALL cross alerts reliably, especially during high-volatility periods where multiple timeframes may signal simultaneously.
This update addresses the common issue where TradingView would suppress multiple alerts firing within seconds of each other, ensuring traders never miss important cross signals.
Release Notes
Update v1.2 - Enhanced Multi-Timeframe Synchronization & Confirmation Logic🎯 Improved Timeframe Confirmation Detection
- Time-based confirmation system: Replaced barstate.isnew with time-based confirmation detection for more reliable bar completion tracking
- Enhanced reliability: Fixes cases where higher timeframe confirmations (1H, 4H, Daily) were missed due to the single-tick nature of barstate.isnew
- Consistent detection: Timeframe confirmations now tracked by monitoring actual time changes rather than relying on volatile tick-based states
⏱️ Smart Confirmation Window Logic
- Multi-timeframe synchronization: When any timeframe confirms, opens a 3-second window to collect confirmations from other aligned timeframes
- Prevents premature alerts: Waits for all relevant timeframes to confirm before processing alerts (e.g., when 1H closes, 15m and 5m may also close within seconds)
- Adaptive processing: Ensures alerts from multiple timeframes closing near-simultaneously are properly captured and queued
🔧 Technical Improvements
- Time-based bar tracking: Monitors actual timeframe time changes instead of ephemeral bar states for more robust confirmation detection
- Eliminated missed confirmations: Time-based approach captures all bar completions regardless of script processing timing
- Enhanced debugging: Added comprehensive logging to monitor confirmation status across all timeframes
📊 Real-World Benefits
- Complete signal capture: No more missed alerts when multiple timeframes align (common during market structure shifts)
- Better synchronization: Properly handles the reality that different timeframes don't close at exactly the same millisecond
- More reliable notifications: Especially important for swing traders using higher timeframes (1H, 4H, Daily)
Technical Note: This update replaces the unreliable barstate.isnew detection (which is only true for a single tick) with a time-based approach that monitors actual timeframe time changes, ensuring no bar completions are missed regardless of when the script processes.
These improvements provide consistent and reliable multi-timeframe signal detection, particularly beneficial during high-volatility periods and market structure changes where multiple timeframes often align
Release Notes
Minor changes with regard to info on alert message.Release Notes
Minor change - MA source default set to 'Last Confirmed Bar'Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.