# Servidor HTTP (Go) > net/http, handlers, ServeMux, middleware, request/response, routing, context - 24 preguntas de entrevista - Mid-Level - [Preguntas de entrevista: Go](https://sharpskill.dev/es/technologies/go/preguntas-entrevista.md) ## 1. ¿Qué es el paquete net/http en Go? **Respuesta** El paquete net/http proporciona la funcionalidad para crear servidores y clientes HTTP. Incluye tipos como http.Server, http.Handler, http.Request, http.ResponseWriter y funciones como ListenAndServe. Es la biblioteca estándar de Go para HTTP, utilizada en la mayoría de las aplicaciones web sin dependencias externas. ## 2. ¿Cómo crear un servidor HTTP simple en Go? **Respuesta** La función http.ListenAndServe inicia un servidor HTTP en un puerto dado con un handler. Toma dos parámetros: la dirección (ej: ':8080') y un handler (puede ser nil para usar DefaultServeMux). Es el método más simple para iniciar un servidor, se bloquea hasta que ocurre un error. ## 3. ¿Qué es un http.Handler en Go? **Respuesta** Un http.Handler es una interfaz con un único método ServeHTTP(ResponseWriter, *Request). Cualquier tipo que implemente este método puede gestionar peticiones HTTP. Es el contrato básico para crear handlers personalizados, middleware y routers. Todos los frameworks web de Go usan esta interfaz como base. ## 21 preguntas más disponibles - ¿Cuál es la diferencia entre http.Handler y http.HandlerFunc? - ¿Para qué sirve http.ServeMux? Regístrate gratis: https://sharpskill.dev/es/login ## Otros temas de entrevista Go - [Fundamentos de Go](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/go-basics.md): 25 preguntas, Junior - [Estructuras de datos en Go](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/go-data-structures.md): 20 preguntas, Junior - [Interfaces en Go](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/go-interfaces.md): 18 preguntas, Junior - [Manejo de errores](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/error-handling.md): 20 preguntas, Junior - [Goroutines básicas](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/goroutines-basics.md): 20 preguntas, Junior - [Channels](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/channels.md): 22 preguntas, Junior - [Go Modules](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/go-modules.md): 18 preguntas, Mid-Level - [Cliente HTTP](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/http-client.md): 18 preguntas, Mid-Level - [Codificación JSON](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/json-encoding.md): 20 preguntas, Mid-Level - [Database/SQL](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/database-sql.md): 22 preguntas, Mid-Level - [Paquete context](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/context-package.md): 20 preguntas, Mid-Level - [Testing](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/testing.md): 22 preguntas, Mid-Level - [Patrones de concurrencia](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/concurrency-patterns.md): 24 preguntas, Mid-Level - [Primitivas de sincronización](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/sync-primitives.md): 22 preguntas, Mid-Level - [Frameworks web de Go](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/go-web-frameworks.md): 20 preguntas, Mid-Level - [Diseño de API REST](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/rest-api-design.md): 20 preguntas, Mid-Level - [gRPC](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/grpc.md): 22 preguntas, Mid-Level - [Reflection](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/reflection.md): 20 preguntas, Senior - [Gestión de memoria](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/memory-management.md): 24 preguntas, Senior - [Optimización del rendimiento](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/performance-optimization.md): 22 preguntas, Senior - [Generics](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/generics.md): 20 preguntas, Senior - [Go Design Patterns](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/design-patterns.md): 24 preguntas, Senior - [Microservices](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/microservices.md): 24 preguntas, Senior - [Seguridad y autenticación](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/security-authentication.md): 24 preguntas, Senior - [Docker & Containerization](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/docker-containerization.md): 20 preguntas, Senior - [Kubernetes Basics](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/kubernetes-basics.md): 22 preguntas, Senior - [Go Avanzado](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/advanced-go.md): 20 preguntas, Senior - [Desarrollo de CLI](https://sharpskill.dev/es/technologies/go/preguntas-entrevista/cli-development.md): 20 preguntas, Senior --- Source: SharpSkill (https://sharpskill.dev), tech interview preparation for your real stack. HTML version of this page: https://sharpskill.dev/es/technologies/go/preguntas-entrevista/http-server