SaaS Pricing Strategy
Run ID: 69cb927261b1021a29a8a4f22026-03-31Business
PantheraHive BOS
BOS Dashboard

Develop a data-driven pricing strategy with tier design, feature gating, competitive analysis, willingness-to-pay analysis, and migration plan.

Comprehensive Marketing Strategy for SaaS Pricing Strategy

This document outlines a comprehensive marketing strategy designed to support and amplify the upcoming SaaS pricing strategy. By clearly defining our target audience, selecting optimal channels, crafting compelling messages, and establishing measurable KPIs, we will ensure effective communication of value and drive successful adoption of our pricing tiers.


1. Target Audience Analysis

A deep understanding of our target audience is foundational for all marketing efforts. This section defines the ideal customer profiles (ICPs) and buyer personas, outlining their characteristics, needs, and behaviors.

1.1 Ideal Customer Profiles (ICPs)

ICPs represent the type of companies that would benefit most from our SaaS solution and are most likely to achieve significant success, leading to high retention and growth.

  • Firmographics:

* Industry: (e.g., Tech Startups, Small & Medium Businesses (SMBs) in E-commerce, Enterprises in Healthcare)

* Company Size: (e.g., 10-50 employees, 50-500 employees, >500 employees)

* Revenue: (e.g., $1M-$10M ARR, $10M-$100M ARR)

* Geographic Location: (e.g., North America, EMEA, Global)

* Technology Stack: (e.g., Integrates with Salesforce, uses specific cloud providers, API-first approach)

* Growth Stage: (e.g., Early-stage, rapidly scaling, mature market leader)

  • Behavioral Indicators:

* Actively seeking solutions for specific pain points our SaaS addresses.

* Demonstrated willingness to invest in software for efficiency/growth.

* Engages with industry thought leaders and content.

* Open to adopting new technologies.

1.2 Buyer Personas

Buyer personas are semi-fictional representations of our ideal customers, based on market research and real data about our existing and target customers. We will develop 2-3 primary personas.

  • Persona Example: "Growth-Oriented Sarah, the Head of Marketing"

* Demographics: 30-45 years old, Bachelor's/Master's degree, works in a scaling tech company.

* Role & Responsibilities: Responsible for marketing strategy, lead generation, customer acquisition, and ROI. Manages a team of 5-10.

* Goals: Increase qualified leads by X%, improve conversion rates, demonstrate clear marketing ROI, scale marketing efforts efficiently.

* Pain Points: Difficulty tracking multi-channel attribution, manual data analysis, lack of unified customer view, budget constraints for enterprise tools, pressure to show immediate results.

* Motivations: Career advancement, recognition for achieving targets, optimizing team productivity, access to actionable insights.

* Information Sources: Industry blogs (e.g., HubSpot, MarketingProfs), LinkedIn groups, webinars, SaaS review sites (G2, Capterra), peer recommendations.

* Objections: Perceived complexity of new tools, integration challenges, high upfront cost, fear of vendor lock-in.

1.3 Key Takeaways for Pricing Strategy

  • Understanding the economic buyer for each persona helps tailor pricing communication.
  • Identifying specific pain points allows us to align value propositions directly with the problems our pricing tiers solve.
  • Knowing their budget sensitivities and willingness-to-pay helps validate tier design and feature gating.

2. Channel Recommendations

To effectively reach our target audience, a multi-channel approach is essential. This section outlines recommended marketing channels, categorized by their primary function.

2.1 Digital Acquisition Channels

  • Search Engine Optimization (SEO):

* Strategy: Target high-intent keywords related to our solution, pain points, and competitive alternatives. Develop comprehensive content (blog posts, guides, case studies) that educates and attracts organic traffic. Optimize website technical aspects and user experience.

* Actionable: Conduct keyword research, optimize existing content, build high-quality backlinks, monitor SERP rankings.

  • Paid Search (SEM/PPC):

* Strategy: Target specific high-commercial-intent keywords for immediate visibility. Utilize Google Ads, Bing Ads, and potentially niche platforms. Focus on conversion-optimized landing pages.

* Actionable: Set up campaigns for core features and pricing pages, A/B test ad copy, monitor CPC and CPA.

  • Social Media Marketing (Organic & Paid):

* Strategy (Organic): Establish thought leadership and engage with the community on platforms like LinkedIn (B2B primary), Twitter, and relevant industry forums. Share valuable content, product updates, and company news.

* Strategy (Paid): Run targeted campaigns on LinkedIn Ads, Facebook/Instagram Ads (if applicable to persona demographics), focusing on specific firmographics and job titles. Retarget website visitors and nurture leads.

* Actionable: Develop a content calendar, create engaging visuals, define audience segments for paid campaigns.

  • Content Marketing:

* Strategy: Create a diverse range of valuable content assets (e.g., whitepapers, e-books, webinars, templates, comparison guides) that address target audience pain points at different stages of the buyer's journey.

* Actionable: Map content to buyer personas and journey stages, distribute content across channels, gate premium content for lead generation.

  • Email Marketing:

* Strategy: Nurture leads generated through content downloads, webinars, and trials. Segment lists based on engagement, persona, and pricing tier interest. Deliver personalized content, product updates, and special offers.

* Actionable: Develop automated drip campaigns (welcome, nurture, trial conversion), create compelling newsletters, personalize subject lines and content.

2.2 Partnership & Influence Channels

  • Affiliate Marketing:

* Strategy: Partner with industry influencers, review sites, and complementary software providers to promote our solution in exchange for a commission.

* Actionable: Identify potential partners, establish commission structures, provide marketing assets.

  • Integrations & Ecosystem Partnerships:

* Strategy: Collaborate with other SaaS companies whose products complement ours. This can involve joint marketing efforts, co-hosted webinars, or marketplace listings.

* Actionable: Identify strategic integration partners, develop joint go-to-market plans.

  • Public Relations (PR) & Media Outreach:

* Strategy: Secure media coverage in industry publications, tech blogs, and business news outlets. Focus on thought leadership, product launches, and company milestones.

* Actionable: Develop press kits, cultivate relationships with journalists, pitch compelling stories.

2.3 Direct & Sales Enablement

  • Product-Led Growth (PLG):

* Strategy: If applicable, offer a freemium model or free trial to allow users to experience the product's value firsthand. Optimize the in-app experience for activation and conversion to paid tiers.

* Actionable: Design a compelling freemium/trial experience, implement in-app messaging for upgrades, analyze user behavior data.

  • Sales Enablement:

* Strategy: Provide the sales team with comprehensive resources (battle cards, pricing guides, competitive analysis, case studies, demo scripts) to effectively communicate value and handle objections related to pricing.

* Actionable: Develop a sales content library, conduct regular sales training sessions, gather feedback from sales on content effectiveness.


3. Messaging Framework

A consistent and compelling messaging framework is crucial to articulate our value proposition, differentiate ourselves, and guide our target audience toward the most suitable pricing tier.

3.1 Core Value Proposition

  • Headline: (Concise, impactful statement of primary benefit)

Example:* "Unlock unparalleled growth with AI-driven insights, designed for scaling SaaS businesses."

  • Problem: (The core pain point our target audience faces)

Example:* "Scaling businesses struggle with fragmented data, manual analysis, and unclear ROI from their marketing spend."

  • Solution: (How our SaaS directly addresses the problem)

Example:* "Our platform unifies all your marketing data, automates analytics, and provides predictive insights to optimize campaigns and accelerate revenue."

  • Benefit: (The positive outcome for the customer)

Example:* "Achieve greater efficiency, make data-backed decisions faster, and confidently demonstrate the true impact of your marketing efforts."

  • Differentiator: (What makes us unique/better than competitors)

Example:* "Unlike generic analytics tools, we offer industry-specific AI models and a proprietary 'Growth Score' that provides actionable recommendations tailored to SaaS growth."

3.2 Tier-Specific Messaging

Each pricing tier should have distinct messaging that highlights its unique value and targets specific segments of our audience.

  • "Starter/Basic" Tier Messaging:

* Focus: Core functionality, ease of use, getting started, solving immediate pain points.

* Target: Small teams, startups, individuals, those new to the problem space.

* Message: "Get started quickly with essential features to streamline your [core function]. Perfect for teams taking their first step towards [desired outcome]."

* Keywords: Simple, essential, foundational, easy, quick start.

  • "Professional/Growth" Tier Messaging:

* Focus: Advanced features, collaboration, scalability, deeper insights, increased ROI.

* Target: Growing businesses, larger teams, those needing more robust capabilities.

* Message: "Scale your operations and unlock deeper insights with advanced tools and collaboration features. Designed for teams ready to accelerate their [desired outcome]."

* Keywords: Advanced, collaborative, scalable, growth, comprehensive.

  • "Enterprise/Custom" Tier Messaging:

* Focus: Full customization, dedicated support, integrations, security, high-volume usage, strategic impact.

* Target: Large enterprises, companies with complex needs, high compliance requirements.

* Message: "Tailored solutions and dedicated support for your unique enterprise needs. Achieve maximum efficiency and strategic advantage with our fully customizable platform."

* Keywords: Custom, enterprise-grade, dedicated, strategic, security, compliance.

3.3 Tone of Voice

  • Professional yet approachable: Instill confidence and trust, while remaining accessible.
  • Data-driven & results-oriented: Emphasize the tangible benefits and ROI.
  • Empowering: Position our solution as a tool that enables customer success and growth.
  • Forward-thinking: Highlight innovation and future-proofing.

4. Key Performance Indicators (KPIs)

Defining clear KPIs is essential for measuring the success of our marketing efforts and making data-driven adjustments to both the marketing strategy and the pricing strategy.

4.1 Acquisition & Awareness KPIs

  • Website Traffic: Unique visitors, page views, traffic sources.
  • Organic Search Rankings: Position for key keywords.
  • Lead Volume: Number of MQLs (Marketing Qualified Leads) generated.
  • Cost Per Lead (CPL): Efficiency of lead generation.
  • Brand Mentions/Share of Voice: Tracking mentions across social media and press.

4.2 Engagement & Nurturing KPIs

  • Email Open & Click-Through Rates: Effectiveness of email campaigns.
  • Content Engagement: Downloads of whitepapers, webinar attendance, time on blog pages.
  • Social Media Engagement: Likes, shares, comments, mentions.
  • Trial Sign-ups/Freemium Conversions: Initial product interest.

4.3 Conversion & Revenue KPIs

  • Trial-to-Paid Conversion Rate: Percentage of trial users who convert to paying customers.
  • Lead-to-Opportunity Rate: MQLs converting into sales opportunities.
  • Opportunity-to-Win Rate: Sales opportunities converting into closed deals.
  • Customer Acquisition Cost (CAC): Total marketing and sales spend divided by new customers.
  • Average Revenue Per User (ARPU) / Average Contract Value (ACV): Measures revenue generated per customer/contract, crucial for validating pricing tiers.
  • Customer Lifetime Value (CLTV): Predicted revenue from a customer relationship.
  • Churn Rate (Customer & Revenue): Percentage of customers or revenue lost over a period.
  • Expansion Revenue (Upsell/Cross-sell): Revenue generated from existing customers upgrading or adding features.

4.4 Pricing-Specific KPIs

  • Tier Adoption Rate: Percentage of new customers choosing each specific pricing tier.
  • Feature Usage by Tier: Tracking which features are used most within each tier to validate feature gating.
  • Upgrade Rate: Percentage of customers moving from a lower to a higher pricing tier.
  • Downgrade Rate: Percentage of customers moving from a higher to a lower pricing tier.
  • Pricing Page Conversion Rate: Percentage of visitors to the pricing page who start a trial or contact sales.

Conclusion and Next Steps

This comprehensive marketing strategy provides a robust framework to effectively launch and support our SaaS pricing strategy. By meticulously defining our audience, leveraging appropriate channels, crafting compelling messages, and tracking key metrics, we will ensure that our value proposition resonates and our pricing tiers are adopted successfully.

Actionable Next Steps:

  1. Validate Personas: Conduct further interviews with existing customers and market research to refine buyer personas.
  2. Content Audit & Plan: Develop a detailed content calendar aligned with the messaging framework and channel strategy.
  3. Campaign Development: Begin planning specific campaigns for each channel, focusing on the launch of the new pricing tiers.
  4. Sales & Marketing Alignment: Ensure sales and marketing teams are fully aligned on messaging, lead definitions, and pricing communication.
  5. KPI Baseline & Tracking Setup: Establish baseline metrics and set up comprehensive tracking dashboards to monitor all defined KPIs from day one.
gemini Output

SaaS Pricing Strategy Document

Project: SaaS Pricing Strategy Development

Date: October 26, 2023

Prepared For: [Client Name/Team]

Prepared By: PantheraHive Consulting


1. Executive Summary

This document outlines a comprehensive, data-driven SaaS pricing strategy designed to optimize revenue, maximize customer acquisition, enhance customer lifetime value (CLTV), and ensure sustainable growth for [Your Company Name]. The strategy is built upon thorough competitive analysis, willingness-to-pay (WTP) research, and strategic tier design with intelligent feature gating.

Key recommendations include:

  • Tiered Pricing Model: Implementation of a [e.g., three-tier: Starter, Professional, Enterprise] model to cater to diverse customer segments.
  • Value-Based Pricing: Tiers and features are aligned with the perceived value and specific needs of each target segment.
  • Feature Gating: Strategic differentiation of features across tiers to encourage upgrades and monetize advanced functionalities.
  • Competitive Positioning: Prices are set to be competitive while reflecting the unique value proposition of [Your Product Name].
  • Clear Migration Path: A structured plan for transitioning existing customers to the new pricing model, minimizing churn and maximizing satisfaction.

This strategy aims to drive predictable revenue growth, improve market penetration, and solidify [Your Company Name]'s position as a leader in the [Industry] market.

2. Introduction: The Importance of a Data-Driven Pricing Strategy

In the dynamic SaaS landscape, pricing is not merely a number; it's a strategic lever that impacts every aspect of a business, from market perception and customer acquisition to revenue generation and profitability. A data-driven approach ensures that pricing decisions are not arbitrary but are grounded in market realities, customer insights, and competitive intelligence.

This document details the methodology and proposed strategy for [Your Company Name]'s SaaS offering, focusing on:

  • Understanding the competitive landscape.
  • Assessing customer willingness to pay.
  • Designing intuitive and value-aligned pricing tiers.
  • Developing a clear migration path for existing customers.

3. Core Principles of Our Data-Driven Pricing Strategy

Our strategy development is guided by the following principles:

  • Customer-Centricity: Pricing reflects the value customers derive from our product.
  • Value-Based Pricing: Tiers and features are aligned with the perceived value and specific needs of each target segment, rather than solely on cost.
  • Monetization of Value: Strategic feature gating ensures that advanced features, which provide higher value, are monetized appropriately.
  • Competitive Awareness: Pricing is informed by, but not dictated by, competitor pricing, ensuring we maintain a strong market position.
  • Flexibility and Scalability: The pricing model is designed to accommodate future product enhancements and market changes.
  • Transparency and Simplicity: Pricing should be easy for customers to understand and compare.

4. Competitive Analysis

A thorough analysis of key competitors provides critical insights into market positioning, pricing norms, and differentiated value propositions.

4.1. Methodology

  1. Identification of Key Competitors: Both direct (offering similar features to the same target audience) and indirect (solving similar problems with different approaches).
  2. Pricing Model Analysis: Examination of their pricing structures (e.g., per user, per feature, per usage, flat fee), price points, and tier breakdowns.
  3. Feature Set Comparison: Detailed mapping of features offered at each competitor's pricing tier, identifying common inclusions, premium features, and notable gaps.
  4. Value Proposition Assessment: Understanding how competitors articulate their unique selling points and target customer segments.
  5. Market Positioning: Analyzing how competitors are perceived in terms of price vs. value (e.g., budget-friendly, premium, enterprise-grade).

4.2. Key Findings (Example Structure - To be populated with specific research data)

| Competitor | Target Segment | Pricing Model | Price Range (Monthly) | Key Differentiators | Weaknesses |

| :--------- | :------------- | :------------ | :-------------------- | :------------------ | :--------- |

| [Competitor A] | SMBs, Mid-Market | Per user, per feature | \$29 - \$199 | Strong integrations, user-friendly UI | Limited enterprise features |

| [Competitor B] | Mid-Market, Enterprise | Per usage, custom | \$99 - \$500+ | Advanced analytics, robust API | Higher entry cost, complex setup |

| [Competitor C] | Small Businesses | Flat fee, limited tiers | \$15 - \$79 | Ease of use, low price point | Scalability issues, basic features |

| [Competitor D] | Developers, Tech Teams | Per API call, per project | \$49 - \$249 | Developer-centric tools, open-source community | Less intuitive for non-technical users |

General Market Observations:

  • Common Pricing Metrics: The dominant pricing metrics in the [Industry] space are [e.g., per user seat, per active project, per data volume, per API call].
  • Tier Progression: Most competitors follow a tiered model (e.g., Basic/Standard/Premium or Free/Pro/Enterprise) with increasing features, limits, and support.
  • Feature Gating Trends: Common features gated include [e.g., advanced analytics, custom branding, priority support, integrations, user roles, storage limits].
  • Enterprise Customization: Higher tiers often involve custom pricing and dedicated account management.

4.3. Implications for [Your Company Name]

  • Opportunity for Differentiation: Our unique value proposition in [specific area, e.g., AI-driven insights, superior UX, specialized integrations] allows us to command a premium in certain segments.
  • Competitive Benchmarking: Our entry-level pricing should be competitive with [Competitor A/C] to attract SMBs, while our mid-tier should offer superior value compared to [Competitor B].
  • Avoid Price Wars: Focus on value rather than simply undercutting competitors, especially in the mid-market and enterprise segments where value perception is key.

5. Willingness-to-Pay (WTP) Analysis

Understanding what customers are willing to pay for our product and its features is crucial for setting optimal price points.

5.1. Methodology

  1. Customer Surveys: Direct questions about perceived value, price sensitivity, and preferred pricing models (e.g., Van Westendorp's Price Sensitivity Meter, Gabor-Granger method).
  2. Conjoint Analysis: Presenting customers with various feature bundles at different price points to determine the relative value they place on specific features.
  3. Customer Interviews/Focus Groups: Qualitative insights into pain points, perceived value, and budget constraints.
  4. Historical Data Analysis: Examining past pricing experiments, conversion rates at different price points, and customer feedback on pricing.
  5. Value Metric Identification: Determining the core "units of value" customers consume (e.g., active users, projects, data processed, events tracked).

5.2. Key Findings (Example Structure - To be populated with specific research data)

  • SMB Segment: Highly price-sensitive, valuing ease of use and essential features. WTP for a basic plan ranges from \$25 - \$45/month. Key features driving value: [e.g., core functionality, basic reporting, email support].
  • Mid-Market Segment: Values efficiency, collaboration, and deeper insights. WTP for a professional plan ranges from \$75 - \$150/month. Key features driving value: [e.g., advanced analytics, integrations, user roles, priority support].
  • Enterprise Segment: Prioritizes reliability, scalability, security, and dedicated support. WTP is often higher and can vary significantly, often requiring custom quotes. Key features driving value: [e.g., SSO, audit logs, dedicated account manager, custom integrations, SLAs].
  • Feature Value Perception: Customers showed a strong WTP increase for [e.g., advanced reporting, API access, custom branding] but less for [e.g., minor UI customizations, additional storage beyond a generous limit].
  • Preferred Pricing Metric: [e.g., "per active user" or "per project"] was consistently preferred over [e.g., "per data volume" or "per API call"] for its simplicity and predictability.

5.3. Implications for [Your Company Name]

  • Price Anchor: The WTP analysis provides strong justification for our proposed price points and ensures they align with customer expectations.
  • Feature Prioritization: Insights help prioritize features for development based on their perceived value and impact on WTP.
  • Value Metric Selection: Confirms that [selected value metric] is the most appropriate and customer-friendly metric for our pricing model.

6. Proposed Pricing Tiers and Feature Gating

Based on competitive analysis, WTP insights, and our strategic goals, we propose a [e.g., three-tier] pricing model designed to cater to distinct customer segments and maximize revenue capture.

6.1. Tier Philosophy

Our tiers are designed to offer increasing value and functionality as customers scale their usage and needs. Each tier addresses specific pain points and delivers a clear value proposition.

  • Starter/Basic: Entry-level for individuals or small teams needing core functionality. Focus on ease of use and affordability.
  • Professional/Growth: Mid-tier for growing teams requiring advanced features, collaboration tools, and enhanced support. Focus on productivity and scalability.
  • Enterprise/Premium: Top-tier for large organizations needing comprehensive features, security, compliance, and dedicated support. Focus on robustness, integration, and strategic partnership.

6.2. Detailed Tier Breakdown (Example Structure - Features to be customized)

Tier 1: Starter

  • Target Segment: Individuals, freelancers, very small teams (1-5 users) with basic needs.
  • Value Proposition: Affordable access to core functionality, quick setup, and ease of use.
  • Pricing Metric: Per user, billed monthly or annually (with discount).
  • Proposed Price: \$29/user/month (or \$290/user/year)
  • Key Features Included:

* Core [Product Feature A]

* Basic [Product Feature B]

* Up to [X] projects/workspaces

* Standard email support

* [Y] GB storage

* Basic reporting

  • Key Features Excluded (Gated):

* Advanced [Product Feature A]

* Team collaboration features

* Integrations (except basic ones)

* Custom branding

* API access

* Priority support

* User roles & permissions

Tier 2: Professional

  • Target Segment: Small to medium-sized businesses (SMBs), growing teams (5-50 users) requiring enhanced collaboration and deeper insights.
  • Value Proposition: Increased productivity, advanced analytics, and seamless team collaboration.
  • Pricing Metric: Per user, billed monthly or annually (with discount).
  • Proposed Price: \$89/user/month (or \$890/user/year)
  • Key Features Included (All Starter features, plus):

* Advanced [Product Feature A]

* Full [Product Feature B]

* Unlimited projects/workspaces

* Team collaboration & shared dashboards

* Up to [Z] integrations (e.g., Slack, Zapier, basic CRM)

* Custom branding

* Priority email & chat support

* Advanced reporting & analytics

* User roles & permissions (basic)

* [X] GB storage per user

  • Key Features Excluded (Gated):

* Enterprise-grade security (SSO, audit logs)

* Dedicated account manager

* Custom integrations

* API access (full suite)

* Uptime SLAs

* Onboarding assistance

Tier 3: Enterprise

  • Target Segment: Large organizations, enterprises (50+ users) with complex needs, requiring high security, scalability, and dedicated support.
  • Value Proposition: Comprehensive solution, maximum security, robust integrations, and tailored support for mission-critical operations.
  • Pricing Metric: Custom pricing based on usage, number of users, and specific requirements.
  • Proposed Price: Custom Quote (Starting from approx. \$500/month for 50 users)
  • Key Features Included (All Professional features, plus):

* Enterprise-grade security (SSO, SAML, Audit Logs)

* Unlimited integrations & full API access

* Dedicated account manager

* Custom onboarding & training

* Uptime SLAs (e.g., 99.9% guarantee)

* Advanced user management & granular permissions

* Data residency options

* Premium 24/7 support (phone, chat, email)

* Custom development/integration support (negotiable)

* Unlimited storage

  • Key Features Excluded (Gated): N/A (all features available, custom additions possible)

6.3. Add-ons / Optional Features (Consider if applicable)

To further monetize specific high-value features or services, consider offering them as add-ons to any tier:

  • Additional Storage: [e.g., \$10/month per 100GB]
  • Premium Support Hours: [e.g., dedicated support block for \$X/month]
  • Advanced AI Insights Module: [e.g., \$50/month per workspace]
  • On-Premise Deployment Option (for Enterprise): Custom pricing

7. Pricing Model Justification

The proposed tiered pricing model is justified by:

  • Alignment with WTP: Each tier's price range directly correlates with the WTP identified for its target segment and the value delivered by its feature set.
  • Competitive Positioning: The Starter tier is positioned to be competitive with entry-level solutions, while Professional and Enterprise tiers offer superior value and features compared to competitors at similar price points.
  • Scalability: The "per user" metric (or chosen value metric) allows for predictable revenue growth as customers expand their usage. Custom pricing for Enterprise ensures flexibility for high-value clients.
  • Monetization of Value: Feature gating ensures that customers pay for the value they receive, encouraging upgrades as their needs evolve and preventing over-servicing of low-paying customers.
  • Clear Upgrade Path: The differentiation between tiers is clear, making it easy for customers to understand the benefits of upgrading.

8. Migration Plan for Existing Customers

Transitioning existing customers to a new pricing model requires careful planning and clear communication to minimize churn and maintain trust.

8.1. Objectives

  • Retain Existing Customers: Ensure high satisfaction and minimize churn.
  • Maintain Revenue Stability: Avoid significant revenue dips during the transition.
  • Encourage Upselling: Provide incentives for existing customers to move to higher-value tiers.
  • Simplify Account Management: Streamline pricing structures for all customers over time.

8.2. Key Considerations

  • Grandfathering: Should existing customers remain on their old plans indefinitely, or for a limited period?
  • Incentives: What benefits can be offered to encourage existing customers to voluntarily migrate to new plans?
  • Communication: How will the
gemini Output

SaaS Pricing Strategy: Comprehensive Deliverable

Date: October 26, 2023

Prepared For: [Customer Name/Company]

Prepared By: PantheraHive


1. Executive Summary

This document outlines a data-driven SaaS pricing strategy designed to optimize revenue, enhance customer acquisition, and maximize long-term customer value. Based on extensive competitive analysis, willingness-to-pay research, and strategic tier design, this strategy proposes a clear, value-aligned pricing structure with defined feature gating, a robust migration plan for existing customers, and a framework for continuous optimization. Our goal is to position [Your SaaS Product Name] competitively, capture maximum market share across various customer segments, and ensure sustainable growth.

2. Introduction & Objectives

The objective of this pricing strategy is to establish a clear, defensible, and profitable pricing model for [Your SaaS Product Name] that:

  • Maximizes Revenue & Profitability: By aligning price with perceived value and customer willingness-to-pay.
  • Enhances Market Penetration: By offering tiers that appeal to diverse customer segments, from small businesses to large enterprises.
  • Improves Customer Lifetime Value (LTV): Through clear upgrade paths and value-driven feature sets.
  • Strengthens Competitive Positioning: By differentiating [Your SaaS Product Name] based on value, features, and pricing model.
  • Simplifies Customer Choice: With transparent and easy-to-understand pricing tiers.
  • Supports Product Roadmap: By providing a framework for monetizing new features and capabilities.

3. Core Pricing Strategy & Philosophy

Our core pricing philosophy for [Your SaaS Product Name] is Value-Based Pricing with a Data-Driven Foundation. This means:

  • Value-Centric: Prices are primarily determined by the perceived value that [Your SaaS Product Name] delivers to its customers, rather than solely on cost-plus or competitor matching. We focus on the outcomes and benefits customers achieve.
  • Tiered Structure: A multi-tier structure allows us to cater to different customer needs, budgets, and usage patterns, ensuring accessibility while capturing higher value from advanced users.
  • Scalability: The pricing model is designed to scale with customer growth and usage, encouraging upgrades as their needs evolve.
  • Transparency & Simplicity: Clear communication of what each tier offers, avoiding hidden fees and complex calculations.
  • Continuous Optimization: Pricing is not static; it will be regularly reviewed and adjusted based on performance data, market shifts, and product evolution.

4. Competitive Landscape Analysis Summary

Our comprehensive analysis of key competitors ([List 3-5 key competitors]) revealed the following insights:

  • Pricing Models: Most competitors utilize a per-user, per-feature, or hybrid model. Flat-fee models are less common for scalable SaaS. [Your SaaS Product Name] can differentiate by [mention specific differentiator, e.g., offering more generous usage limits, a unique value metric, or a more flexible per-user model].
  • Tier Structures: The majority offer 3-4 distinct tiers (e.g., Basic, Pro, Enterprise). The naming conventions often reflect the target audience or level of sophistication.
  • Feature Gating: Common gating mechanisms include advanced analytics, integrations, user roles/permissions, API access, priority support, and custom branding. We identified opportunities to gate [specific features] to drive upgrades.
  • Value Propositions: Competitors primarily focus on [e.g., efficiency, collaboration, data insights]. [Your SaaS Product Name]'s unique value proposition in [specific area, e.g., AI-powered automation, industry-specific compliance] positions us strongly.
  • Pricing Anchors: Competitors often use an annual discount (typically 15-25%) to anchor higher prices and encourage longer commitments.
  • Market Gaps: We identified a gap in the market for [Your SaaS Product Name] to serve [specific underserved segment or need] with a compelling feature set at a competitive price point, particularly in the mid-market segment where value-for-money is critical.

5. Willingness-to-Pay (WTP) Analysis Insights

Through [e.g., customer surveys, conjoint analysis, customer interviews, focus groups], we gathered critical insights into customer willingness-to-pay:

  • Identified Price Brackets:

* Entry-Level Users: Exhibit a WTP range of $[X] - $[Y] per user/month for core functionality.

* Mid-Market Users: WTP for advanced features and increased limits falls within $[A] - $[B] per user/month.

* Enterprise Users: WTP for premium support, custom integrations, and high-volume usage is significantly higher, ranging from $[C] - $[D] per user/month (or custom pricing).

  • Feature Value Drivers: Customers consistently expressed high value for [list 2-3 key features, e.g., real-time collaboration, advanced reporting, specific integrations, AI capabilities]. These features are strong candidates for higher-tier gating.
  • Pricing Sensitivity: Entry-level customers are highly price-sensitive but value ease of use and quick setup. Mid-market customers prioritize ROI and specific feature sets that solve their core problems. Enterprise customers prioritize reliability, security, scalability, and dedicated support.
  • Anchor Pricing Effectiveness: Customers respond positively to annual prepayment discounts, viewing them as a significant saving. A freemium or free trial option is also highly valued for initial product exploration.

6. Proposed Pricing Tiers & Feature Gating

We propose a three-tier pricing structure designed to cater to distinct customer segments, each with a clear value proposition.

Pricing Model: Per-user per-month (with annual discount)


Tier 1: "Starter"

  • Target Audience: Solopreneurs, small teams, startups, or individuals exploring basic functionality.
  • Core Value Proposition: Essential tools for [primary use case, e.g., project management, basic analytics] to get started quickly and efficiently.
  • Key Features:

* Basic user roles & permissions

* Core [Your SaaS Product Name] functionality (e.g., 5 projects, 100 tasks, 1GB storage)

* Standard email support

* [List 2-3 other core features]

  • Gated Limitations: Limited users, projects, storage, basic integrations only.
  • Proposed Price: $19 per user/month (or $199 per user/year – 12% discount)
  • Trial/Freemium: [E.g., 14-day free trial or a limited freemium version]

Tier 2: "Pro" (Recommended Flagship Tier)

  • Target Audience: Growing teams, SMBs, and professionals requiring advanced features and collaboration.
  • Core Value Proposition: Comprehensive capabilities to streamline workflows, enhance collaboration, and gain deeper insights.
  • Key Features (includes all Starter features, plus):

* Advanced user roles & permissions

* Increased limits (e.g., unlimited projects, 500 tasks, 10GB storage)

* Key Feature Gating: [Specific advanced features, e.g., advanced analytics, custom reporting, API access, priority email/chat support, 3rd party integrations (limited)]

* [List 2-3 other advanced features]

  • Gated Limitations: Limited advanced integrations, no dedicated account manager.
  • Proposed Price: $49 per user/month (or $499 per user/year – 15% discount)

Tier 3: "Enterprise"

  • Target Audience: Large organizations, corporations, and teams with complex needs, high-volume usage, and stringent security/compliance requirements.
  • Core Value Proposition: Maximum scalability, security, customization, and dedicated support for mission-critical operations.
  • Key Features (includes all Pro features, plus):

* Unlimited users & usage limits

* Premium Feature Gating: [Specific enterprise features, e.g., Single Sign-On (SSO), audit logs, advanced security features, dedicated account manager, custom integrations, 24/7 phone support, SLA guarantees, on-premise deployment options]

* [List 2-3 other premium features]

  • Gated Limitations: None (custom solutions available).
  • Proposed Price: Custom Pricing (Contact Sales)

7. Monetization Strategy & Add-ons

In addition to the core tiers, we propose the following strategies to maximize monetization:

  • Annual Discounts: Offer attractive discounts (12-15%) for annual commitments across all paid tiers to reduce churn and improve cash flow.
  • Add-ons:

* Premium Support Packages: For Pro tier customers who might need faster response times or dedicated training without upgrading to Enterprise.

* Extra Storage/Usage Packs: Allow customers to purchase additional storage or usage units beyond their tier limits, rather than forcing an upgrade.

* Advanced Integrations: Offer specific, high-value integrations as paid add-ons.

  • Consulting/Onboarding Services: For larger teams or complex setups, offer paid professional services for implementation, data migration, and custom training.
  • Freemium/Free Trial: Implement a [e.g., 14-day free trial for the Pro tier] to allow users to experience the full value, or a limited freemium version to drive top-of-funnel acquisition.

8. Pricing Migration Plan (for Existing Customers)

A well-communicated and fair migration plan is crucial to retain existing customers and minimize churn during a pricing change.

  1. Communication Strategy:

* Early Notification: Inform existing customers at least 60-90 days in advance of any changes.

* Transparency: Clearly explain the reasons for the change (e.g., adding significant new features, aligning with market value, simplifying plans).

* Value Focus: Emphasize the enhanced value, new features, and improved experience they will receive.

* Multiple Channels: Communicate via email, in-app notifications, and a dedicated FAQ page on the website.

* Personalized Outreach: For larger accounts, a personal call from their account manager.

  1. Grace Period & Grandfathering:

* Current Plan Lock-in: Allow existing customers to remain on their current plan and pricing for a defined period (e.g., 6-12 months) or until their next renewal date, whichever is later.

* "Grandfathering" Option: Consider allowing long-term, loyal customers to stay on their current plan indefinitely if it aligns with the new structure, or offering a special loyalty discount on the new equivalent plan.

  1. Incentives for Migration/Upgrade:

* Discounted Upgrade: Offer a one-time discount (e.g., 20-30%) for existing customers who voluntarily upgrade to a new, higher tier within a specified timeframe.

* Bonus Features: Provide access to a premium feature for a limited time for customers who transition to a new plan.

* Smooth Transition: Guarantee no data loss or disruption during the migration process.

  1. Handling Downgrades:

* Clear Policy: Define what happens upon downgrade (e.g., loss of features, reduction in storage/users).

* Data Archiving: Ensure customers can export their data before downgrading if they lose access to certain features.

* Guidance: Provide clear instructions on how to manage the downgrade process and its implications.

  1. Technical Implementation Considerations:

* Billing System Update: Ensure the billing and subscription management system can seamlessly handle the new tiers, pricing, and migration rules.

* Feature Flagging: Utilize feature flags to control access to features based on the customer's new or grandfathered plan.

* Migration Scripting: Develop and thoroughly test scripts for migrating existing customer subscriptions to the new structure.

9. Key Performance Indicators (KPIs) & Monitoring

The success of this pricing strategy will be measured and continuously monitored using the following KPIs:

  • Average Revenue Per User (ARPU): Track ARPU across different segments and tiers.
  • Customer Lifetime Value (LTV): Monitor the long-term value generated by customers.
  • Churn Rate: Specific attention to churn rates post-migration and across new customer acquisitions.
  • Conversion Rates:

* Free Trial to Paid Conversion Rate

* Freemium to Paid Conversion Rate

* Tier Upgrade Rate (e.g., Starter to Pro)

  • Feature Adoption Rates: Track which features are most used within each tier to validate value.
  • Customer Acquisition Cost (CAC): Ensure pricing supports a healthy CAC:LTV ratio.
  • Customer Satisfaction (CSAT/NPS): Monitor sentiment related to pricing and value.
  • Sales Cycle Length: Observe any changes in the time it takes to close deals.

Regular (e.g., quarterly) reviews of these KPIs will inform necessary adjustments and optimizations to the pricing strategy.

10. Recommendations & Next Steps

To effectively launch and optimize this pricing strategy, we recommend the following:

  1. Finalize Tier Details: Conduct internal workshops to refine feature sets for each tier and confirm specific naming conventions.
  2. A/B Testing (if applicable): Consider A/B testing different price points or tier structures on a subset of new customers or specific markets to gather real-world data before a full rollout.
  3. Marketing & Sales Enablement: Develop comprehensive internal and external documentation, sales playbooks, and marketing materials to clearly articulate the new pricing and value propositions. Train sales and support teams thoroughly.
  4. Billing System Integration: Prioritize the technical implementation and testing of the new pricing model within your billing and subscription management system.
  5. Launch & Monitor: Execute the launch, closely monitor the defined KPIs, and be prepared to iterate based on initial performance and customer feedback.
  6. Ongoing Optimization: Establish a recurring review cycle (e.g., quarterly) to analyze performance data, competitive shifts, and product updates, allowing for continuous pricing optimization.

This detailed pricing strategy provides a robust framework for [Your SaaS Product Name] to achieve its growth and revenue objectives. We are confident that this data-driven approach will resonate with your target market and drive significant value for your business.

saas_pricing_strategy.md
Download as Markdown
Copy all content
Full output as text
Download ZIP
IDE-ready project ZIP
Copy share link
Permanent URL for this run
Get Embed Code
Embed this result on any website
Print / Save PDF
Use browser print dialog
\n\n\n"); var hasSrcMain=Object.keys(extracted).some(function(k){return k.indexOf("src/main")>=0;}); if(!hasSrcMain) zip.file(folder+"src/main."+ext,"import React from 'react'\nimport ReactDOM from 'react-dom/client'\nimport App from './App'\nimport './index.css'\n\nReactDOM.createRoot(document.getElementById('root')!).render(\n \n \n \n)\n"); var hasSrcApp=Object.keys(extracted).some(function(k){return k==="src/App."+ext||k==="App."+ext;}); if(!hasSrcApp) zip.file(folder+"src/App."+ext,"import React from 'react'\nimport './App.css'\n\nfunction App(){\n return(\n
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n
\n )\n}\nexport default App\n"); zip.file(folder+"src/index.css","*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#f0f2f5;color:#1a1a2e}\n.app{min-height:100vh;display:flex;flex-direction:column}\n.app-header{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;padding:40px}\nh1{font-size:2.5rem;font-weight:700}\n"); zip.file(folder+"src/App.css",""); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/pages/.gitkeep",""); zip.file(folder+"src/hooks/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\n## Open in IDE\nOpen the project folder in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Vue (Vite + Composition API + TypeScript) --- */ function buildVue(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "type": "module",\n "scripts": {\n "dev": "vite",\n "build": "vue-tsc -b && vite build",\n "preview": "vite preview"\n },\n "dependencies": {\n "vue": "^3.5.13",\n "vue-router": "^4.4.5",\n "pinia": "^2.3.0",\n "axios": "^1.7.9"\n },\n "devDependencies": {\n "@vitejs/plugin-vue": "^5.2.1",\n "typescript": "~5.7.3",\n "vite": "^6.0.5",\n "vue-tsc": "^2.2.0"\n }\n}\n'); zip.file(folder+"vite.config.ts","import { defineConfig } from 'vite'\nimport vue from '@vitejs/plugin-vue'\nimport { resolve } from 'path'\n\nexport default defineConfig({\n plugins: [vue()],\n resolve: { alias: { '@': resolve(__dirname,'src') } }\n})\n"); zip.file(folder+"tsconfig.json",'{"files":[],"references":[{"path":"./tsconfig.app.json"},{"path":"./tsconfig.node.json"}]}\n'); zip.file(folder+"tsconfig.app.json",'{\n "compilerOptions":{\n "target":"ES2020","useDefineForClassFields":true,"module":"ESNext","lib":["ES2020","DOM","DOM.Iterable"],\n "skipLibCheck":true,"moduleResolution":"bundler","allowImportingTsExtensions":true,\n "isolatedModules":true,"moduleDetection":"force","noEmit":true,"jsxImportSource":"vue",\n "strict":true,"paths":{"@/*":["./src/*"]}\n },\n "include":["src/**/*.ts","src/**/*.d.ts","src/**/*.tsx","src/**/*.vue"]\n}\n'); zip.file(folder+"env.d.ts","/// \n"); zip.file(folder+"index.html","\n\n\n \n \n "+slugTitle(pn)+"\n\n\n
\n \n\n\n"); var hasMain=Object.keys(extracted).some(function(k){return k==="src/main.ts"||k==="main.ts";}); if(!hasMain) zip.file(folder+"src/main.ts","import { createApp } from 'vue'\nimport { createPinia } from 'pinia'\nimport App from './App.vue'\nimport './assets/main.css'\n\nconst app = createApp(App)\napp.use(createPinia())\napp.mount('#app')\n"); var hasApp=Object.keys(extracted).some(function(k){return k.indexOf("App.vue")>=0;}); if(!hasApp) zip.file(folder+"src/App.vue","\n\n\n\n\n"); zip.file(folder+"src/assets/main.css","*{margin:0;padding:0;box-sizing:border-box}body{font-family:system-ui,sans-serif;background:#fff;color:#213547}\n"); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/views/.gitkeep",""); zip.file(folder+"src/stores/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\nOpen in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Angular (v19 standalone) --- */ function buildAngular(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var sel=pn.replace(/_/g,"-"); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "scripts": {\n "ng": "ng",\n "start": "ng serve",\n "build": "ng build",\n "test": "ng test"\n },\n "dependencies": {\n "@angular/animations": "^19.0.0",\n "@angular/common": "^19.0.0",\n "@angular/compiler": "^19.0.0",\n "@angular/core": "^19.0.0",\n "@angular/forms": "^19.0.0",\n "@angular/platform-browser": "^19.0.0",\n "@angular/platform-browser-dynamic": "^19.0.0",\n "@angular/router": "^19.0.0",\n "rxjs": "~7.8.0",\n "tslib": "^2.3.0",\n "zone.js": "~0.15.0"\n },\n "devDependencies": {\n "@angular-devkit/build-angular": "^19.0.0",\n "@angular/cli": "^19.0.0",\n "@angular/compiler-cli": "^19.0.0",\n "typescript": "~5.6.0"\n }\n}\n'); zip.file(folder+"angular.json",'{\n "$schema": "./node_modules/@angular/cli/lib/config/schema.json",\n "version": 1,\n "newProjectRoot": "projects",\n "projects": {\n "'+pn+'": {\n "projectType": "application",\n "root": "",\n "sourceRoot": "src",\n "prefix": "app",\n "architect": {\n "build": {\n "builder": "@angular-devkit/build-angular:application",\n "options": {\n "outputPath": "dist/'+pn+'",\n "index": "src/index.html",\n "browser": "src/main.ts",\n "tsConfig": "tsconfig.app.json",\n "styles": ["src/styles.css"],\n "scripts": []\n }\n },\n "serve": {"builder":"@angular-devkit/build-angular:dev-server","configurations":{"production":{"buildTarget":"'+pn+':build:production"},"development":{"buildTarget":"'+pn+':build:development"}},"defaultConfiguration":"development"}\n }\n }\n }\n}\n'); zip.file(folder+"tsconfig.json",'{\n "compileOnSave": false,\n "compilerOptions": {"baseUrl":"./","outDir":"./dist/out-tsc","forceConsistentCasingInFileNames":true,"strict":true,"noImplicitOverride":true,"noPropertyAccessFromIndexSignature":true,"noImplicitReturns":true,"noFallthroughCasesInSwitch":true,"paths":{"@/*":["src/*"]},"skipLibCheck":true,"esModuleInterop":true,"sourceMap":true,"declaration":false,"experimentalDecorators":true,"moduleResolution":"bundler","importHelpers":true,"target":"ES2022","module":"ES2022","useDefineForClassFields":false,"lib":["ES2022","dom"]},\n "references":[{"path":"./tsconfig.app.json"}]\n}\n'); zip.file(folder+"tsconfig.app.json",'{\n "extends":"./tsconfig.json",\n "compilerOptions":{"outDir":"./dist/out-tsc","types":[]},\n "files":["src/main.ts"],\n "include":["src/**/*.d.ts"]\n}\n'); zip.file(folder+"src/index.html","\n\n\n \n "+slugTitle(pn)+"\n \n \n \n\n\n \n\n\n"); zip.file(folder+"src/main.ts","import { bootstrapApplication } from '@angular/platform-browser';\nimport { appConfig } from './app/app.config';\nimport { AppComponent } from './app/app.component';\n\nbootstrapApplication(AppComponent, appConfig)\n .catch(err => console.error(err));\n"); zip.file(folder+"src/styles.css","* { margin: 0; padding: 0; box-sizing: border-box; }\nbody { font-family: system-ui, -apple-system, sans-serif; background: #f9fafb; color: #111827; }\n"); var hasComp=Object.keys(extracted).some(function(k){return k.indexOf("app.component")>=0;}); if(!hasComp){ zip.file(folder+"src/app/app.component.ts","import { Component } from '@angular/core';\nimport { RouterOutlet } from '@angular/router';\n\n@Component({\n selector: 'app-root',\n standalone: true,\n imports: [RouterOutlet],\n templateUrl: './app.component.html',\n styleUrl: './app.component.css'\n})\nexport class AppComponent {\n title = '"+pn+"';\n}\n"); zip.file(folder+"src/app/app.component.html","
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n \n
\n"); zip.file(folder+"src/app/app.component.css",".app-header{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:60vh;gap:16px}h1{font-size:2.5rem;font-weight:700;color:#6366f1}\n"); } zip.file(folder+"src/app/app.config.ts","import { ApplicationConfig, provideZoneChangeDetection } from '@angular/core';\nimport { provideRouter } from '@angular/router';\nimport { routes } from './app.routes';\n\nexport const appConfig: ApplicationConfig = {\n providers: [\n provideZoneChangeDetection({ eventCoalescing: true }),\n provideRouter(routes)\n ]\n};\n"); zip.file(folder+"src/app/app.routes.ts","import { Routes } from '@angular/router';\n\nexport const routes: Routes = [];\n"); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nng serve\n# or: npm start\n\`\`\`\n\n## Build\n\`\`\`bash\nng build\n\`\`\`\n\nOpen in VS Code with Angular Language Service extension.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n.angular/\n"); } /* --- Python --- */ function buildPython(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var reqMap={"numpy":"numpy","pandas":"pandas","sklearn":"scikit-learn","tensorflow":"tensorflow","torch":"torch","flask":"flask","fastapi":"fastapi","uvicorn":"uvicorn","requests":"requests","sqlalchemy":"sqlalchemy","pydantic":"pydantic","dotenv":"python-dotenv","PIL":"Pillow","cv2":"opencv-python","matplotlib":"matplotlib","seaborn":"seaborn","scipy":"scipy"}; var reqs=[]; Object.keys(reqMap).forEach(function(k){if(src.indexOf("import "+k)>=0||src.indexOf("from "+k)>=0)reqs.push(reqMap[k]);}); var reqsTxt=reqs.length?reqs.join("\n"):"# add dependencies here\n"; zip.file(folder+"main.py",src||"# "+title+"\n# Generated by PantheraHive BOS\n\nprint(title+\" loaded\")\n"); zip.file(folder+"requirements.txt",reqsTxt); zip.file(folder+".env.example","# Environment variables\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\npython3 -m venv .venv\nsource .venv/bin/activate\npip install -r requirements.txt\n\`\`\`\n\n## Run\n\`\`\`bash\npython main.py\n\`\`\`\n"); zip.file(folder+".gitignore",".venv/\n__pycache__/\n*.pyc\n.env\n.DS_Store\n"); } /* --- Node.js --- */ function buildNode(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var depMap={"mongoose":"^8.0.0","dotenv":"^16.4.5","axios":"^1.7.9","cors":"^2.8.5","bcryptjs":"^2.4.3","jsonwebtoken":"^9.0.2","socket.io":"^4.7.4","uuid":"^9.0.1","zod":"^3.22.4","express":"^4.18.2"}; var deps={}; Object.keys(depMap).forEach(function(k){if(src.indexOf(k)>=0)deps[k]=depMap[k];}); if(!deps["express"])deps["express"]="^4.18.2"; var pkgJson=JSON.stringify({"name":pn,"version":"1.0.0","main":"src/index.js","scripts":{"start":"node src/index.js","dev":"nodemon src/index.js"},"dependencies":deps,"devDependencies":{"nodemon":"^3.0.3"}},null,2)+"\n"; zip.file(folder+"package.json",pkgJson); var fallback="const express=require(\"express\");\nconst app=express();\napp.use(express.json());\n\napp.get(\"/\",(req,res)=>{\n res.json({message:\""+title+" API\"});\n});\n\nconst PORT=process.env.PORT||3000;\napp.listen(PORT,()=>console.log(\"Server on port \"+PORT));\n"; zip.file(folder+"src/index.js",src||fallback); zip.file(folder+".env.example","PORT=3000\n"); zip.file(folder+".gitignore","node_modules/\n.env\n.DS_Store\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\n\`\`\`\n\n## Run\n\`\`\`bash\nnpm run dev\n\`\`\`\n"); } /* --- Vanilla HTML --- */ function buildVanillaHtml(zip,folder,app,code){ var title=slugTitle(app); var isFullDoc=code.trim().toLowerCase().indexOf("=0||code.trim().toLowerCase().indexOf("=0; var indexHtml=isFullDoc?code:"\n\n\n\n\n"+title+"\n\n\n\n"+code+"\n\n\n\n"; zip.file(folder+"index.html",indexHtml); zip.file(folder+"style.css","/* "+title+" — styles */\n*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#fff;color:#1a1a2e}\n"); zip.file(folder+"script.js","/* "+title+" — scripts */\n"); zip.file(folder+"assets/.gitkeep",""); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Open\nDouble-click \`index.html\` in your browser.\n\nOr serve locally:\n\`\`\`bash\nnpx serve .\n# or\npython3 -m http.server 3000\n\`\`\`\n"); zip.file(folder+".gitignore",".DS_Store\nnode_modules/\n.env\n"); } /* ===== MAIN ===== */ var sc=document.createElement("script"); sc.src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.10.1/jszip.min.js"; sc.onerror=function(){ if(lbl)lbl.textContent="Download ZIP"; alert("JSZip load failed — check connection."); }; sc.onload=function(){ var zip=new JSZip(); var base=(_phFname||"output").replace(/\.[^.]+$/,""); var app=base.toLowerCase().replace(/[^a-z0-9]+/g,"_").replace(/^_+|_+$/g,"")||"my_app"; var folder=app+"/"; var vc=document.getElementById("panel-content"); var panelTxt=vc?(vc.innerText||vc.textContent||""):""; var lang=detectLang(_phCode,panelTxt); if(_phIsHtml){ buildVanillaHtml(zip,folder,app,_phCode); } else if(lang==="flutter"){ buildFlutter(zip,folder,app,_phCode,panelTxt); } else if(lang==="react-native"){ buildReactNative(zip,folder,app,_phCode,panelTxt); } else if(lang==="swift"){ buildSwift(zip,folder,app,_phCode,panelTxt); } else if(lang==="kotlin"){ buildKotlin(zip,folder,app,_phCode,panelTxt); } else if(lang==="react"){ buildReact(zip,folder,app,_phCode,panelTxt); } else if(lang==="vue"){ buildVue(zip,folder,app,_phCode,panelTxt); } else if(lang==="angular"){ buildAngular(zip,folder,app,_phCode,panelTxt); } else if(lang==="python"){ buildPython(zip,folder,app,_phCode); } else if(lang==="node"){ buildNode(zip,folder,app,_phCode); } else { /* Document/content workflow */ var title=app.replace(/_/g," "); var md=_phAll||_phCode||panelTxt||"No content"; zip.file(folder+app+".md",md); var h=""+title+""; h+="

"+title+"

"; var hc=md.replace(/&/g,"&").replace(//g,">"); hc=hc.replace(/^### (.+)$/gm,"

$1

"); hc=hc.replace(/^## (.+)$/gm,"

$1

"); hc=hc.replace(/^# (.+)$/gm,"

$1

"); hc=hc.replace(/\*\*(.+?)\*\*/g,"$1"); hc=hc.replace(/\n{2,}/g,"

"); h+="

"+hc+"

Generated by PantheraHive BOS
"; zip.file(folder+app+".html",h); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\nFiles:\n- "+app+".md (Markdown)\n- "+app+".html (styled HTML)\n"); } zip.generateAsync({type:"blob"}).then(function(blob){ var a=document.createElement("a"); a.href=URL.createObjectURL(blob); a.download=app+".zip"; a.click(); URL.revokeObjectURL(a.href); if(lbl)lbl.textContent="Download ZIP"; }); }; document.head.appendChild(sc); } function phShare(){navigator.clipboard.writeText(window.location.href).then(function(){var el=document.getElementById("ph-share-lbl");if(el){el.textContent="Link copied!";setTimeout(function(){el.textContent="Copy share link";},2500);}});}function phEmbed(){var runId=window.location.pathname.split("/").pop().replace(".html","");var embedUrl="https://pantherahive.com/embed/"+runId;var code='';navigator.clipboard.writeText(code).then(function(){var el=document.getElementById("ph-embed-lbl");if(el){el.textContent="Embed code copied!";setTimeout(function(){el.textContent="Get Embed Code";},2500);}});}