Sitecore-10-NET-Developer Sample Questions

Sitecore-10-NET-Developer Sample Questions & Answers

Platform architecture and patching carry the biggest weight, next to rendering and component layout, installation and security for developers, item and data template foundations, the Item API, content search setup, content versioning, and personalization rules.

Launch the full Sitecore-10-NET-Developer simulator →

Showing 10 of 20 free samples.

  1. Question 1Intermediate

    Content Search · Index Configuration

    A website's search functionality is returning inaccurate results for product specifications stored in a 'Rich Text' field. The field contains HTML markup, and searches for terms inside tags (e.g., 'strong') are matching, which is undesirable. To fix this, the search index needs to store a plain-text version of the content. What is the most appropriate way to configure this in Sitecore's content search?

    Show answer & explanation

    Correct answer: C

    Sitecore provides a built-in HtmlStripFieldReader specifically for this purpose. By mapping the rich text field type to this reader in the index configuration's , you instruct the indexing process to automatically strip all HTML tags before the content is sent to the search provider (like Solr). This is the standard, most efficient way to handle this common requirement without writing custom code.

  2. Question 2Beginner

    Rendering and Layout · Data Sources

    A developer has created a Controller Rendering for a 'Call to Action' component. The component needs a data source item to provide the button text and link. To ensure content authors can easily select a valid data source, the developer wants to restrict the selection to items based on the 'CallToActionData' template, located under /sitecore/content/Global/CTAs. Which field on the rendering item should be configured to enable this?

    Show answer & explanation

    Correct answer: B

    The 'Datasource Location' field on a rendering item is used to specify the root item(s) from which content authors can select a data source. It supports Sitecore queries. Combining this with the 'Datasource Template' field (which specifies the required template) provides a robust and user-friendly authoring experience in the Experience Editor.

  3. Question 3Beginner

    Personalization · Rule Set Editor

    A marketing team wants to display a promotional banner to visitors who arrive at the website from a specific marketing campaign. The campaign is tagged with the UTM code utm_campaign=summer_sale. Using the Rule Set Editor, which condition should be used to identify these visitors?

    Show answer & explanation

    Correct answer: B

    Sitecore automatically processes UTM parameters and triggers internal campaign events. The correct way to personalize based on a campaign is to use the condition that checks if a specific campaign was triggered during the current interaction. This rule directly evaluates the campaign data captured by Sitecore's analytics.

  4. Question 4Beginner

    Sitecore Structure & Platform · Patch File Management

    True or False: In a standard Sitecore 10 installation, patch files located in the App_Config/Include/Project folder will always be loaded before files in the App_Config/Include/Feature folder.

    Show answer & explanation

    Correct answer: B

    False. By default, Sitecore loads configuration files alphabetically by folder and then by file name. However, the Layers.config file explicitly defines the load order for Helix-style folders, ensuring that Foundation, Feature, and then Project layers are loaded in that sequence. Therefore, files in the Feature folder are loaded before files in the Project folder.

  5. Question 5Intermediate

    Item and Data Foundations · Content Serialization

    A developer is using the Sitecore CLI to serialize content items for source control. After running dotnet sitecore ser pull, they notice that a newly created template is not being serialized. The module.json file contains the following rule for templates:

    {
    "namespace": "MyProject.Templates",
    "path": "/sitecore/templates/Project/MyProject",
    "scope": "ItemAndDescendants",
    "allowedPushOperations": "CreateUpdateAndDelete"
    }
    

    The new template was created at /sitecore/templates/Feature/MyFeature. What is the reason for this issue?

    Show answer & explanation

    Correct answer: B

    Sitecore Content Serialization relies on rules defined in module.json files to determine which items to include. The rule shown only covers items under /sitecore/templates/Project/MyProject. Since the new template was created in /sitecore/templates/Feature/MyFeature, it falls outside the specified path and is therefore ignored by the serialization process. A new rule would need to be added for the Feature folder.

  6. Question 6Advanced

    System Administration for Developers · Docker Container Deployment

    During a Sitecore installation using a Docker container environment for local development, a developer is unable to access the Identity Server login page, receiving a 500 error. Reviewing the Identity Server container logs, they find an error stating 'The client application is not known or is not authorized'. Which file is most likely misconfigured, causing this authentication issue between the CM instance and the Identity Server?

    Show answer & explanation

    Correct answer: C

    This error typically occurs when there's a mismatch in secrets or hostnames between the CM and Identity Server. In a standard Docker setup, the CM_HOST and ID_HOST variables are defined in the .env file. A common mistake is having an incorrect CM_HOST value, which causes the Identity Server to reject requests from the CM instance because the redirectUri or postLogoutRedirectUri in the CM's configuration doesn't match what the Identity Server expects for that client.

  7. Question 7Beginner

    Rendering and Layout · Field Renderers

    A developer needs to render a 'General Link' field named 'CTA Link' from the current item within a CSHTML view. The goal is to render the full tag with all attributes (href, title, target, class) as configured by the content author. Which Razor syntax should be used to achieve this?

    Show answer & explanation

    Correct answer: A

    The @Html.Sitecore().Field() helper is the standard and correct way to render Sitecore fields in an MVC view. For complex field types like 'General Link', this helper automatically generates the appropriate HTML markup, including the tag and all its attributes as defined in the Content Editor. It also supports rendering in Experience Editor mode.

  8. Question 8Advanced

    Sitecore API · Item Editing and Locking

    A developer is building a custom solution that needs to programmatically add a new version to an item in a specific language, but only if the item is not already locked by another user. What is the correct Sitecore API approach to safely perform this action?

    sequenceDiagram participant Code as Custom Code participant Item as Sitecore Item participant DB as Database Code->>Item: Check if locked alt Item is NOT locked Code->>Item: BeginEdit() Code->>Item: Versions.AddVersion() Code->>Item: EndEdit() Item->>DB: Save Changes else Item is locked Code->>Log: Log warning 'Item is locked' end

    Show answer & explanation

    Correct answer: B

    The correct and safest procedure is to first check the lock status using item.Locking.IsLocked(). If the item is not locked by someone else, you should then wrap the modification logic within an ItemEditing context (using (new ItemEditing(item, true))) or by calling item.Editing.BeginEdit() and item.Editing.EndEdit(). Inside this context, you can safely call item.Versions.AddVersion(). This ensures atomicity and proper event firing.

  9. Question 9Advanced

    Content Search · LINQ and Search API

    A search query for blog posts needs to be filtered by a 'Tags' field, which is a 'Treelist' field type. The query should return only posts where at least one of the selected tags is 'Technology' (ID: {GUID-A}) OR 'Development' (ID: {GUID-B}). Given a LINQ query context IQueryable query, which predicate is correct for this requirement?

    Show answer & explanation

    Correct answer: C

    For multi-list fields like Treelist, Sitecore indexes the GUIDs in a way that allows for Contains checks. To implement an OR condition, you should use the logical OR operator (||) within the predicate. The .Filter() method is often used interchangeably with .Where() in this context and is translated correctly by the LINQ provider to the underlying search engine's query syntax.

  10. Question 10Intermediate

    Personalization · Testing Strategies

    A marketing team is running an A/B test on a homepage banner component to see which version leads to more clicks on a 'Learn More' button. The 'Learn More' button click is configured as a Sitecore Goal named 'LearnMoreClicked'. How can the marketing team determine the winning version of the test based on this goal?

    Show answer & explanation

    Correct answer: A

    Sitecore's A/B testing framework is tightly integrated with its analytics capabilities. When a test is active, the Experience Optimization or Experience Analytics applications will show the performance of each test variant. The key metric for determining a winner is 'Trailing Value/Visit', which is calculated based on the engagement value of goals triggered by users who were exposed to that variant. The variant with the highest trailing value for the 'LearnMoreClicked' goal is the winner.

Ready for the real thing?

The full Sitecore-10-NET-Developer simulator has every exam-style question, timed mode, and instant scoring.